Is it possible to have the line of an error?

Thomas Lindgren thomasl_erlang@REDACTED
Wed Jul 9 14:48:38 CEST 2003


--- WILLIAMS Dominic <D.WILLIAMS@REDACTED>
wrote:

> Is it possible to know the line of the failure? I am
> looking for something like compile options or
> activating traces, rather than peppering my code
> with macros and ?LINE...

Ideally, the system would provide such information on
its own, but that is not yet a feature.

Parse transforms may be what you want. I have written
and used a parse transform (smart_exceptions) that
provides line information and a bit more for most
exceptions. In the same framework, you can also write
your own custom exception handlers. 

I will prepare it for "external use" and check it into
jungerl in a couple of days.

Best,
Thomas


__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com



More information about the erlang-questions mailing list