on master help sign in
Fix "Force" in case tree for new indexed form
commit89c89d36b81e36fbed3374ab9f2774b9aecd1ed7 authorEdwin Brady <eb@cs.st-andrews.ac.uk> dateWed 26 Mar 2014, 20:02 (13 years ago) parent577752b
1 file changed+2−2
src/Idris/Core/CaseTree.hs+2−2
src/Idris/Core/CaseTree.hs+2−2
@@ -159,7 +159,7 @@ directUse fn@(App f a)
159159 | (P Ref (UN pfk) _, [App e w]) <- unApply fn,
160160 pfk == txt "prim_fork"
161161 = directUse e ++ directUse w -- HACK so that fork works
162− | (P Ref (UN fce) _, [_, a]) <- unApply fn,
162+ | (P Ref (UN fce) _, [_, _, a]) <- unApply fn,
163163 fce == txt "Force"
164164 = directUse a -- forcing a value counts as a use
165165 | (P Ref n _, args) <- unApply fn = [] -- need to know what n does with them
@@ -626,7 +626,7 @@ prune proj (Case n alts)
626626
627627 forceTm n arg t = subst arg (forceArg n) t
628628
629− forceArg n = App (App (P Ref (sUN "Force") Erased) Erased)
629+ forceArg n = App (App (App (P Ref (sUN "Force") Erased) Erased) Erased)
630630 (P Bound n Erased)
631631
632632 mkProj n i [] sc = prune proj sc