[Git][ghc/ghc][wip/torsten.schmits/23612] don't use binders for fvs in IfaceTickish
Torsten Schmits (@torsten.schmits)
gitlab at gitlab.haskell.org
Wed Sep 27 23:51:55 UTC 2023
Torsten Schmits pushed to branch wip/torsten.schmits/23612 at Glasgow Haskell Compiler / GHC
Commits:
cd6e4558 by Torsten Schmits at 2023-09-28T01:51:46+02:00
don't use binders for fvs in IfaceTickish
- - - - -
3 changed files:
- compiler/GHC/CoreToIface.hs
- compiler/GHC/Iface/Syntax.hs
- compiler/GHC/IfaceToCore.hs
Changes:
=====================================
compiler/GHC/CoreToIface.hs
=====================================
@@ -574,7 +574,7 @@ toIfaceTickish (HpcTick modl ix) = IfaceHpcTick modl ix
toIfaceTickish (SourceNote src (LexicalFastString names)) =
IfaceSource src names
toIfaceTickish (Breakpoint _ ix fv m) =
- IfaceBreakpoint ix (toIfaceIdBndr <$> fv) m
+ IfaceBreakpoint ix (toIfaceVar <$> fv) m
---------------------
toIfaceBind :: Bind Id -> IfaceBinding IfaceLetBndr
=====================================
compiler/GHC/Iface/Syntax.hs
=====================================
@@ -635,7 +635,7 @@ data IfaceTickish
= IfaceHpcTick Module Int -- from HpcTick x
| IfaceSCC CostCentre Bool Bool -- from ProfNote
| IfaceSource RealSrcSpan FastString -- from SourceNote
- | IfaceBreakpoint Int [IfaceIdBndr] Module -- from Breakpoint
+ | IfaceBreakpoint Int [IfaceExpr] Module -- from Breakpoint
data IfaceAlt = IfaceAlt IfaceConAlt [IfLclName] IfaceExpr
-- Note: IfLclName, not IfaceBndr (and same with the case binder)
=====================================
compiler/GHC/IfaceToCore.hs
=====================================
@@ -1624,8 +1624,8 @@ tcIfaceTickish (IfaceHpcTick modl ix) = return (HpcTick modl ix)
tcIfaceTickish (IfaceSCC cc tick push) = return (ProfNote cc tick push)
tcIfaceTickish (IfaceSource src name) = return (SourceNote src (LexicalFastString name))
tcIfaceTickish (IfaceBreakpoint ix fvs modl) = do
- fvs' <- bindIfaceIds fvs pure
- return (Breakpoint NoExtField ix fvs' modl)
+ fvs' <- mapM tcIfaceExpr fvs
+ return (Breakpoint NoExtField ix [f | Var f <- fvs'] modl)
-------------------------
tcIfaceLit :: Literal -> IfL Literal
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/cd6e455854c1554befd38833c5496d2bcd076b08
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/cd6e455854c1554befd38833c5496d2bcd076b08
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/20230927/46cbf21f/attachment-0001.html>
More information about the ghc-commits
mailing list