Skip to content
  • Alan Zimmerman's avatar
    parser: opt_kind_sig has incorrect SrcSpan · 8aefc9b7
    Alan Zimmerman authored
    The production for opt_kind_sig is
    
      opt_kind_sig :: { Located (Maybe (LHsKind RdrName)) }
              :                             { noLoc Nothing }
              | '::' kind                   {% ajl (sLL $1 $> (Just $2)) AnnDcolon (gl $1) }
    
    The outer Location is used only to get the full span for the enclosing
    declration, and is then stripped. The inner LHsKind then has a SrcSpan that does
    not include the '::'
    
    Extend the SrcSpan on $2 to include $1
    
    Reviewed By: austin
    
    Differential Revision: https://phabricator.haskell.org/D813
    
    GHC Trac Issues: #10209
    8aefc9b7