LINE and COLUMN pragmas
Alan & Kim Zimmerman
alan.zimm at gmail.com
Mon May 12 18:01:32 UTC 2025
I recently discovered the `UsePosPragsBit` in the lexer, which can allow
emitting the LINE and COLUMN pragmas as tokens instead of processing them
directly in the Lexer, updating the position.
When exact printing, this behaviour is not desirable.
So I am putting together an MR to parse them if they appear, so they do not
cause a parser crash, and they can then be exact printed.
Question: Where should these pragmas appear in HsDecl
Options are
- TTG, XXHsDecl
- A new HsDecl constructor, with all its concomitant matching everywhere
- tuck it in elsewhere, e.g. in `AnnDecl` (or `XXAnnDecl`).
Alan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-devs/attachments/20250512/17793fc2/attachment.html>
More information about the ghc-devs
mailing list