
30 Oct
2006
30 Oct
'06
7:58 p.m.
On Mon, Oct 30, 2006 at 10:16:46AM -0500, Lennart Augustsson wrote:
I like to use undefined is the stub for unimplemented functions since it's nice and terse. Unfortunately, ghc doesn't give much information about where the undefined was called. It would be great if the message for undefined could include file name and line number (like hbc did :).
jhc has the SRCLOC_ANNOTATE pragma, which lets you attach file and line number information to arbitrary functions. sort of a generalization of the 'assert' feature of ghc. One day I will get around to implementing it in ghc. perhaps the next time a program I write mysteriously dies with "Prelude.undefined" being the only thing printed. John -- John Meacham - ⑆repetae.net⑆john⑈