forked from GitHub/gf-core
preperations for Val of params
This commit is contained in:
@@ -356,7 +356,7 @@ computeTermOpt rec gr = comput True where
|
||||
ptyp <- comp g pty0
|
||||
case allParamValues gr ptyp of
|
||||
Ok vs0 -> do
|
||||
let vs = [Val v ptyp i | (v,i) <- zip vs0 [0..]]
|
||||
let vs = vs0 ---- [Val v ptyp i | (v,i) <- zip vs0 [0..]]
|
||||
ps0 <- mapM (compPatternMacro . fst) cs
|
||||
cs' <- mapM (compBranchOpt g) (zip ps0 (map snd cs))
|
||||
sts <- mapM (matchPattern cs') vs
|
||||
|
||||
@@ -492,7 +492,7 @@ term2term fun cgr env@(labels,untyps,typs) tr = case tr of
|
||||
_ | tr == x -> t
|
||||
_ -> GM.composSafeOp (mkBranch x t) tr
|
||||
|
||||
valNum (Val _ _ i) = EInt $ toInteger i
|
||||
valNum (Val _ _ i) = traceD (show i) $ EInt $ toInteger i ----Val
|
||||
valNum tr = maybe (valNumFV $ tryFV tr) EInt $ Map.lookup tr untyps
|
||||
where
|
||||
tryFV tr = case GM.appForm tr of
|
||||
|
||||
Reference in New Issue
Block a user