Skip to content
  • Rodrigo Mesquita's avatar
    TTG: Refactor bracket for desugaring during tc · 4a2567f5
    Rodrigo Mesquita authored and Marge Bot's avatar Marge Bot committed
    When desugaring a bracket we want to desugar /renamed/ rather than
    /typechecked/ code; So in (HsExpr GhcTc) tree, we must
    have a (HsExpr GhcRn) for the quotation itself.
    
    This commit reworks the TTG refactor on typed and untyped brackets by
    storing the /renamed/ code in the bracket field extension rather than in
    the constructor extension in `HsQuote` (previously called
    `HsUntypedBracket`)
    
    See Note [The life cycle of a TH quotation] and ghc/ghc!4782
    4a2567f5