Now (base 4.9.0.0) ErrorCall contain field for stacktrace information and error fills it.

If you add field for stacktrace information to SomeException

data SomeException where SomeExceptionWithLocation :: Exception e => String -> e -> SomeException pattern SomeException :: () => Exception e => e -> SomeException pattern SomeException err <- SomeExceptionWithLocation _ err where SomeException err = SomeExceptionWithLocation "" err

and will fills it in throw

throw :: ( HasCallStack , Exception e ) => e -> a throw e = unsafeDupablePerformIO $ do stack <- currentCallStack raise # ( CallStackException e $ if stack /= [] then prettyCallStack ? callStack ++ "

" ++ renderStack stack else prettyCallStack ? callStack )

it will be more useful for ghci users.