Skip to content

Commit

Permalink
Merge pull request #136 from Profpatsch/main
Browse files Browse the repository at this point in the history
Meta: add HsProjection for GHC >9.6
  • Loading branch information
guibou authored Apr 22, 2024
2 parents 450400b + 632f625 commit 8beb2d4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/PyF/Internal/Meta.hs
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,7 @@ toExp _ (HsOverLabel _ Nothing lbl) = TH.LabelE (unpackFS lbl)
#endif
#if MIN_VERSION_ghc(9,6,0)
toExp dynFlags (HsGetField _ expr field) = TH.GetFieldE (toExp dynFlags (unLoc expr)) (unpackFS . field_label . unLoc . dfoLabel . unLoc $ field)
toExp _ (HsProjection _ fields) = TH.ProjectionE (fmap (unpackFS . unLoc . fmap field_label . dfoLabel . unLoc) fields)
#elif MIN_VERSION_ghc(9, 4, 0)
toExp dynFlags (HsGetField _ expr field) = TH.GetFieldE (toExp dynFlags (unLoc expr)) (unpackFS . unLoc . dfoLabel . unLoc $ field)
toExp _ (HsProjection _ fields) = TH.ProjectionE (fmap (unpackFS . unLoc . dfoLabel . unLoc) fields)
Expand Down

0 comments on commit 8beb2d4

Please sign in to comment.