@@ -276,7 +276,7 @@ mkPE_TermDecl :: IState
276 -> [(PEArgType, Term)]
276 -> [(PEArgType, Term)]
277 -> PEDecl
277 -> PEDecl
278mkPE_TermDecl ist newname sname specty ns
278mkPE_TermDecl ist newname sname specty ns
279− {- We need to erase the *dynamic* arguments
279+ {- We need to erase the *dynamic* arguments
280 where their *name* appears in the *type* of a later argument
280 where their *name* appears in the *type* of a later argument
281 in specty.
281 in specty.
282 i.e. if a later dynamic argument depends on an earlier dynamic
282 i.e. if a later dynamic argument depends on an earlier dynamic
@@ -285,12 +285,12 @@ mkPE_TermDecl ist newname sname specty ns
285 on the RHS.
285 on the RHS.
287 = let deps = getDepNames (eraseRet specty)
287 = let deps = getDepNames (eraseRet specty)
288− lhs = eraseDeps deps $
288+ lhs = eraseDeps deps $
289 PApp emptyFC (PRef emptyFC [] newname) (mkp ns)
289 PApp emptyFC (PRef emptyFC [] newname) (mkp ns)
290 rhs = eraseDeps deps $
290 rhs = eraseDeps deps $
291 delab ist (mkApp (P Ref sname Erased) (map snd ns))
291 delab ist (mkApp (P Ref sname Erased) (map snd ns))
292 patdef = -- trace (showTmImpls specty ++ "\n" ++ showTmImpls lhs ++ "\n"
292 patdef = -- trace (showTmImpls specty ++ "\n" ++ showTmImpls lhs ++ "\n"
293− -- ++ showTmImpls rhs) $
293+ -- ++ showTmImpls rhs) $
294 lookupCtxtExact sname (idris_patdefs ist)
294 lookupCtxtExact sname (idris_patdefs ist)
295 newpats = case patdef of
295 newpats = case patdef of
296 Nothing -> PEDecl lhs rhs [(lhs, rhs)] True
296 Nothing -> PEDecl lhs rhs [(lhs, rhs)] True
@@ -305,7 +305,7 @@ mkPE_TermDecl ist newname sname specty ns
306 -- Get names used in later arguments; assume we've called eraseRet so there's
306 -- Get names used in later arguments; assume we've called eraseRet so there's
307 -- no names going to appear in return type
307 -- no names going to appear in return type
308− getDepNames (PPi _ n _ _ sc)
308+ getDepNames (PPi _ n _ _ sc)
309 | n `elem` allNamesIn sc = n : getDepNames sc
309 | n `elem` allNamesIn sc = n : getDepNames sc
310 | otherwise = getDepNames sc
310 | otherwise = getDepNames sc
311 getDepNames tm = []
311 getDepNames tm = []
@@ -337,7 +337,7 @@ getSpecApps ist env tm = ga env (explicitNames tm) where
337 | Just n <- imparg imp = (ImplicitS n, tm)
337 | Just n <- imparg imp = (ImplicitS n, tm)
338 | constrarg imp = (ConstraintS, tm)
338 | constrarg imp = (ConstraintS, tm)
339 | otherwise = (ExplicitS, tm)
339 | otherwise = (ExplicitS, tm)
341 staticArg env False imp tm n
341 staticArg env False imp tm n
342 | Just nm <- imparg imp = (ImplicitD nm, (P Ref (sUN (show n ++ "arg")) Erased))
342 | Just nm <- imparg imp = (ImplicitD nm, (P Ref (sUN (show n ++ "arg")) Erased))
343 | constrarg imp = (ConstraintD, tm)
343 | constrarg imp = (ConstraintD, tm)