
* Neil Mitchell
Apart from this, HSE now also parses any unrecognized pragma in option (e.g. LANGUAGE), declaration (e.g. RULES) or expression (e.g. SCC) position, allowing user-customized pragmas. Unrecognized pragmas in other positions will (unfortunately) give a parse error. If this ever means a problem for you - let me know!
This is likely to be a problem for me :-)
I certainly have OPTIONS_DERIVE and CATCH pragmas that I've inserted into various programs over time. I think failing on an unrecognised pragma is probably a bad idea, when ignoring a pragma is usually perfectly safe.
Even more, An implementation is not required to respect any pragma, but the pragma should be ignored if an implementation is not prepared to handle it.[1] Related question: why does not Language.Haskell.Syntax[2] (from haskell-src) represent comments or pragmas in any way? 1. http://www.haskell.org/onlinereport/pragmas.html 2. http://www.haskell.org/ghc/docs/latest/html/libraries/haskell-src/Language-H... -- Roman I. Cheplyaka :: http://ro-che.info/ "Don't let school get in the way of your education." - Mark Twain