[GHC] #11140: add command-line option to GHC to dump raw parse trees of Haskell programs

GHC ghc-devs at haskell.org
Wed May 18 10:01:51 UTC 2016


#11140: add command-line option to GHC to dump raw parse trees of Haskell programs
-------------------------------------+-------------------------------------
        Reporter:  bollu             |                Owner:
            Type:  feature request   |               Status:  new
        Priority:  low               |            Milestone:
       Component:  Compiler          |              Version:  7.10.2
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by mpickering):

 Because I think it would be useful when working on the parser to see the
 parse trees. It is often not obvious how the parser works, see for example
 the recent work I have been doing with export lists and there's another
 ticket about how `BooleanFormula` is parsed in a very strange way. Both
 would be easier to debug with this flag.

 There is already precedent for this, after all the other stages in the
 compiler pipeline there is an flag which dumps the correct compiler output
 (`-ddump-simple`, `-ddump-rn`, `-ddump-rn` etc) so why not for dumping
 parse trees as well?

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


More information about the ghc-tickets mailing list