Skip to content
  • Matthew Pickering's avatar
    Ignore comments in getOptions · 5d6133be
    Matthew Pickering authored and Ben Gamari's avatar Ben Gamari committed
    When Opt_KeepRawTokenStream is turned on then getOptions fails to find
    the language pragmas which can cause unexpected parse errors when using
    the GHC API. A simple solution is to make it skip over any comments in
    the token
    stream.
    
    Test Plan: ./validate
    
    Reviewers: austin, bgamari
    
    Subscribers: alanz, thomie
    
    Differential Revision: https://phabricator.haskell.org/D1444
    
    GHC Trac Issues: #10942
    5d6133be