• Ryan Scott's avatar
    Properly designate LambdaCase alts as CaseAlt in TH · 32008a9d
    Ryan Scott authored
    When `\case` expressions are parsed normally, their
    alternatives are marked as `CaseAlt` (which means that they are
    pretty-printed without a `\` character in front of them, unlike for
    lambda expressions). However, `\case` expressions created by way of
    Template Haskell (in `Convert`) inconsistently designated the case
    alternatives as `LambdaExpr`, causing them to be pretty-printed
    poorly (as shown in #15518). The fix is simple: use `CaseAlt`
    Test Plan: make test TEST=T15518
    Reviewers: goldfire, bgamari
    Subscribers: rwbarton, carter
    GHC Trac Issues: #15518
    Differential Revision: https://phabricator.haskell.org/D5069
all.T 19 KB