[Git][ghc/ghc][master] EPA: do not duplicate comments in signature RHS
Marge Bot (@marge-bot)
gitlab at gitlab.haskell.org
Tue Mar 26 02:20:34 UTC 2024
Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC
Commits:
d2ba41e8 by Alan Zimmerman at 2024-03-25T22:19:51-04:00
EPA: do not duplicate comments in signature RHS
- - - - -
1 changed file:
- compiler/GHC/Hs/Utils.hs
Changes:
=====================================
compiler/GHC/Hs/Utils.hs
=====================================
@@ -736,12 +736,12 @@ mkBigLHsPatTup = mkChunkified mkLHsPatTup
-- | Convert an 'LHsType' to an 'LHsSigType'.
hsTypeToHsSigType :: LHsType GhcPs -> LHsSigType GhcPs
-hsTypeToHsSigType lty@(L loc ty) = L loc $ case ty of
+hsTypeToHsSigType lty@(L loc ty) = case ty of
HsForAllTy { hst_tele = HsForAllInvis { hsf_xinvis = an
, hsf_invis_bndrs = bndrs }
, hst_body = body }
- -> mkHsExplicitSigType an bndrs body
- _ -> mkHsImplicitSigType lty
+ -> L loc $ mkHsExplicitSigType an bndrs body
+ _ -> L (l2l loc) $ mkHsImplicitSigType lty -- The annotations are in lty, erase them from loc
-- | Convert an 'LHsType' to an 'LHsSigWcType'.
hsTypeToHsSigWcType :: LHsType GhcPs -> LHsSigWcType GhcPs
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/d2ba41e8c3e71d70a0f80dcc3f588ecbdc5ce4b2
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/d2ba41e8c3e71d70a0f80dcc3f588ecbdc5ce4b2
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20240325/7f80755c/attachment-0001.html>
More information about the ghc-commits
mailing list