[GHC] #10558: Alter type of parseDeclaration and parseTypeSignature entry points

GHC ghc-devs at haskell.org
Mon Jun 22 00:31:52 UTC 2015


#10558: Alter type of parseDeclaration and parseTypeSignature entry points
-------------------------------------+-------------------------------------
              Reporter:  mpickering  |             Owner:
                  Type:  bug         |            Status:  new
              Priority:  normal      |         Milestone:
             Component:  Compiler    |           Version:  7.10.1
              Keywords:              |  Operating System:  Unknown/Multiple
          Architecture:              |   Type of failure:  None/Unknown
  Unknown/Multiple                   |        Blocked By:
             Test Case:              |   Related Tickets:
              Blocking:              |
Differential Revisions:  Phab:       |
  D1007                              |
-------------------------------------+-------------------------------------
 Currently the type of the two mentioned entry points is

 {{{#!hs
 parseDeclaration :: P (OrdList (LHsDecl RdrName))
 }}}

 and

 {{{#!hs
 parseTypeSignature :: P (Located (OrdList (LHsDecl RdrName)))
 }}}

 It turns out that in both cases, OrdList is always a singleton so the
 additional wrapping is redundant. I propose that the parser is modified in
 order to reflect this so that this is clearer to end users. The end result
 being that both entry points have type `P (LHsDecl RdrName)`

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10558>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list