alanz / ghc-exactprint

GHC version of haskell-src-exts exactPrint
BSD 3-Clause "New" or "Revised" License
70 stars 32 forks source link

"pure" parser: Fix shebang treatment, Expose relevant internal #61

Closed lspitzner closed 6 years ago

lspitzner commented 6 years ago

(this makes the fix for https://github.com/lspitzner/brittany/issues/92 a bit easier.)

mpickering commented 6 years ago

I probably don’t understand but stripping line pragmas seems like the wrong thing to do in general?

lspitzner commented 6 years ago

But all other parseModule* functions call stripLinePragmas. And this PR does not affect parseWith (which would be the more general function). Or what "in general" do you have in mind?

(or should line pragma stripping and shebang stripping be distinct? not sure about the details there either.)

mpickering commented 6 years ago

Ah ignore me then. Thanks for the PR.