[Haskell-beginners] :trace seems not to work in ghci
Sam Coles
sammuel.coles at gmail.com
Thu Sep 26 22:19:41 CEST 2013
I think the modules need to be interpreted try using.
Prelude> :l *Main
On Thu, Sep 26, 2013 at 5:35 AM, Nathan Hüsken <nathan.huesken at posteo.de>wrote:
> Hey,
>
> I have a program I want to debug in ghci because it crashes with an
> exception. So I do:
>
> Prelude> :l Main
> Ok, modules loaded: Main, PlotDisplay, PlotDiagram, ForexData.
> Prelude Main> :set -fbreak-on-exception
> Prelude Main> :trace main
> (...)
> Stopped at <exception thrown>
> _exception :: e = _
> [<exception thrown>] Prelude Main> :hist
> Empty history. Perhaps you forgot to use :trace?
> [<exception thrown>] Prelude Main> :back
> no more logged breakpoints
> [<exception thrown>] Prelude Main> :force _exception
> _exception = GHC.Exception.SomeException
> (GHC.Exception.ErrorCall "Prelude.tail: empty list")
>
> What could be the reason why :hist/:back/:trace are not working?
>
> Thanks!
> Nathan
> ______________________________**_________________
> Beginners mailing list
> Beginners at haskell.org
> http://www.haskell.org/**mailman/listinfo/beginners<http://www.haskell.org/mailman/listinfo/beginners>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/beginners/attachments/20130926/3fa472fb/attachment.htm>
More information about the Beginners
mailing list