Commit 302aee52 authored by Ben Gamari's avatar Ben Gamari Committed by Ben Gamari

base: Refactor Show ErrorCall instance into proper ShowS style

Test Plan: Validate

Reviewers: hvr, dfeuer

Reviewed By: dfeuer

Subscribers: dfeuer, rwbarton, thomie, carter

Differential Revision:
parent 66961dc8
......@@ -184,7 +184,8 @@ instance Exception ErrorCall
-- | @since
instance Show ErrorCall where
showsPrec _ (ErrorCallWithLocation err "") = showString err
showsPrec _ (ErrorCallWithLocation err loc) = showString (err ++ '\n' : loc)
showsPrec _ (ErrorCallWithLocation err loc) =
showString err . showChar '\n' . showString loc
errorCallException :: String -> SomeException
errorCallException s = toException (ErrorCall s)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment