From 9935e99c893b9d5eb0a879116144cf62cc986e7d Mon Sep 17 00:00:00 2001 From: Shayne Fletcher Date: Sun, 2 May 2021 16:56:55 -0400 Subject: Change representation of HsGetField and HsProjection Another change in a series improving record syntax in the AST. The key change in this commit is the renaming of `HsFieldLabel` to `DotFieldOcc`. --- compiler/GHC/Hs/Expr.hs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'compiler/GHC/Hs/Expr.hs') diff --git a/compiler/GHC/Hs/Expr.hs b/compiler/GHC/Hs/Expr.hs index 89292b59c3..006c8a2e8e 100644 --- a/compiler/GHC/Hs/Expr.hs +++ b/compiler/GHC/Hs/Expr.hs @@ -44,6 +44,7 @@ import GHC.Parser.Annotation -- others: import GHC.Tc.Types.Evidence +import GHC.Core.DataCon (FieldLabelString) import GHC.Types.Name import GHC.Types.Name.Set import GHC.Types.Basic @@ -406,8 +407,8 @@ data AnnsIf type instance XSCC (GhcPass _) = EpAnn AnnPragma type instance XXPragE (GhcPass _) = NoExtCon -type instance XCHsFieldLabel (GhcPass _) = EpAnn AnnFieldLabel -type instance XXHsFieldLabel (GhcPass _) = NoExtCon +type instance XCDotFieldOcc (GhcPass _) = EpAnn AnnFieldLabel +type instance XXDotFieldOcc (GhcPass _) = NoExtCon type instance XPresent (GhcPass _) = EpAnn [AddEpAnn] @@ -1902,6 +1903,8 @@ type instance Anno [LocatedA (StmtLR (GhcPass pl) (GhcPass pr) (LocatedA (HsExpr type instance Anno [LocatedA (StmtLR (GhcPass pl) (GhcPass pr) (LocatedA (HsCmd (GhcPass pr))))] = SrcSpanAnnL type instance Anno (FieldLabelStrings (GhcPass p)) = SrcSpan +type instance Anno (FieldLabelString) = SrcSpan +type instance Anno (DotFieldOcc (GhcPass p)) = SrcSpan instance (Anno a ~ SrcSpanAnn' (EpAnn an)) => WrapXRec (GhcPass p) a where -- cgit v1.2.1