Skip to content
Snippets Groups Projects
Forked from Glasgow Haskell Compiler / GHC
47840 commits behind the upstream repository.
  • Simon Marlow's avatar
    c197fe60
    FIX #3079, dodgy parsing of LANGUAGE pragmas · c197fe60
    Simon Marlow authored
    I ended up rewriting this horrible bit of code, using (yikes) lazy I/O
    to slurp in the source file a chunk at a time.  The old code tried to
    read the file a chunk at a time, but failed with LANGUAGE pragmas
    because the parser for LANGUAGE has state and the state wasn't being
    saved between chunks.  We're still closing the Handle eagerly, so
    there shouldn't be any problems here.
    c197fe60
    History
    FIX #3079, dodgy parsing of LANGUAGE pragmas
    Simon Marlow authored
    I ended up rewriting this horrible bit of code, using (yikes) lazy I/O
    to slurp in the source file a chunk at a time.  The old code tried to
    read the file a chunk at a time, but failed with LANGUAGE pragmas
    because the parser for LANGUAGE has state and the state wasn't being
    saved between chunks.  We're still closing the Handle eagerly, so
    there shouldn't be any problems here.
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
HeaderInfo.hs 9.63 KiB