TTG: move phase-specific constructors
The goal of this ticket is to move phase-specific constructors to extension fields (Trees That Grow) - make illegal states unrepresentable.
- (done !2083 (closed))
HsWrap
is specific to typechecking, should be insideXExpr
. - (done !2553 (closed))
ConPatIn
andConPatOut
could become a singleConPat
with fields depending on the pass. - (done !2553 (closed)) Perhaps
CoPat
too. - (in progress !3524)
HsRecFld
occurs only at theGhcRn
phase. - (in progress !3524 or !4782)
HsRnBracketOut
occurs only at theGhcRn
phase. - (in progress !4782)
HsTcBracketOut
occurs only at theGhcTc
phase. - (in progress !4782)
AbsBinds
occurs only at theGhcTc
phase. -
HsTick
andHsBinTick
occur only at theGhcTc
phase. -
HsConLikeOut
occurs only at theGhcTc
phase. -
HsSpliced
could be moved toXSplice
. - Perhaps
HsUnboundVar
,HsIPVar
,HsOverLabel
which occur inGhcPs
andGhcRn
but notGhcTc
.
(Initial idea mentioned by Simon and Richard during Zurihac)