We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
First reported in ndmitchell/hlint#1122 by @pbrisbin
Suppose the content of Foo.hs is
Foo.hs
#!/usr/bin/env stack {- stack --resolver lts-16.10 script -} module Main (main) where main :: IO () main = putStrLn "hi"
In the following program, only the first way of parsing Foo.hs preserves the shebang.
import Language.Haskell.GHC.ExactPrint.Parsers import Language.Haskell.GHC.ExactPrint.Print main :: IO () main = do Right (as, m) <- parseModule "test/Foo.hs" -- preserves shebang Right (as, m) <- parseModule "./test/Foo.hs" -- loses shebang Right (as, m) <- parseModule "Foo.hs" -- loses shebang Right (as, m) <- parseModule "./Foo.hs" -- loses shebang Right (as, m) <- parseModule "/tmp/Foo.hs" -- loses shebang putStrLn $ exactPrint m as
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
First reported in ndmitchell/hlint#1122 by @pbrisbin
Suppose the content of
Foo.hs
isIn the following program, only the first way of parsing
Foo.hs
preserves the shebang.The text was updated successfully, but these errors were encountered: