RE: patch applied (ghc): Adding a GENERATED pragma

Simon Peyton-Jones <[email protected]>
Newsgroups gmane.comp.lang.haskell.cvs.all,gmane.comp.lang.haskell.cvs.ghc
Message-ID <DCA83D5F3861C941808187D4D38787503705656C@EA-EXMSG-C312.europe.corp.microsoft.com>
Andy: if GENERATED stays, can you document it in the user manual please?
LINE is documented at 7.10.5


| -----Original Message-----
| From: Andy Gill [mailto:[email protected]]
| Sent: 29 December 2006 23:18
| To: Duncan Coutts
| Cc: Simon Peyton-Jones; [email protected]
| Subject: Re: patch applied (ghc): Adding a GENERATED pragma
|
| >
| > LINE can already refer to an external non-.hs file. This is exactly
| > how
| > things works now with all manner of pre-processors, alex, happy,
| > cpphs,
| > c2hs, hsc2hs, etc.
| >
| > I don't quite have an intuition for this yet, can you give an
| > example of
| > how this more fine grained pragma works and some use-case not
| > currently
| > covered by LINE?
| >
|
| Ahhh. LINE does? Oh.
|
| - GENERATED works on an expression based level, and can specify
| specific spans.
|    (20:4 - 21:8, for example).
|   - GENERATED is a true pragma; it hints where things come from, but
| does not change
|    the error message. I want the Haskell source spans to remain
| unchanges.
|
| But perhaps a variant of LINE would be a better name.
|
| Andy
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.