Skip to content

Commit

Permalink
Remove call to deShadowBinds
Browse files Browse the repository at this point in the history
deShadowBinds is not used in GHC and currently panics when
used in Liquid Haskell. This removal should help discover
what is needed for.
  • Loading branch information
facundominguez committed Nov 7, 2023
1 parent e146308 commit 32499d7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion liquidhaskell-boot/src-ghc/Liquid/GHC/API.hs
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ import GHC.Core.Make as Ghc
import GHC.Core.Predicate as Ghc (getClassPredTys_maybe, getClassPredTys, isEvVarType, isEqPrimPred, isEqPred, isClassPred, isDictId, mkClassPred)
import GHC.Core.Reduction as Ghc
( Reduction(Reduction) )
import GHC.Core.Subst as Ghc (deShadowBinds, emptySubst, extendCvSubst)
import GHC.Core.Subst as Ghc (emptySubst, extendCvSubst)
import GHC.Core.TyCo.Rep as Ghc
( AnonArgFlag(VisArg)
, ArgFlag(Required)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,10 @@ failingBinds info = filter (hasErrors . checkBind) structBinds

checkBind :: CoreBind -> Result ()
checkBind bind = do
srcCallInfo <- getCallInfoBind emptyEnv (deShadowBind bind)
srcCallInfo <- getCallInfoBind emptyEnv bind
let structCallInfo = fmap toStructCall <$> srcCallInfo
fold $ mapWithFun structDecreasing structCallInfo

deShadowBind :: CoreBind -> CoreBind
deShadowBind bind = head $ deShadowBinds [bind]

findStructBinds :: HashSet Var -> CoreProgram -> [CoreBind]
findStructBinds structFuns program = filter isStructBind program
where
Expand Down

0 comments on commit 32499d7

Please sign in to comment.