From 25b260ab966d002c83f4b7778bcd71b762a302d8 Mon Sep 17 00:00:00 2001 From: herbelin Date: Tue, 25 Sep 2007 09:01:24 +0000 Subject: Suppression de tous les alias de la forme x:=x dans la compilation du filtrage. git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@10140 85f007b7-540e-0410-9357-904b9bb8a0f7 --- pretyping/cases.ml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/pretyping/cases.ml b/pretyping/cases.ml index 6ac1c8a166..fd8f24370a 100644 --- a/pretyping/cases.ml +++ b/pretyping/cases.ml @@ -112,12 +112,11 @@ type alias_constr = let mkSpecialLetInJudge j (na,(deppat,nondeppat,d,t)) = { uj_val = - (match d with + (if isRel deppat then subst1 nondeppat j.uj_val + else match d with | DepAlias -> mkLetIn (na,deppat,t,j.uj_val) | NonDepAlias -> - if (not (dependent (mkRel 1) j.uj_type)) - or (* A leaf: *) isRel deppat - then + if (not (dependent (mkRel 1) j.uj_type)) then (* The body of pat is not needed to type j - see *) (* insert_aliases - and both deppat and nondeppat have the *) (* same type, then one can freely substitute one by the other *) -- cgit v1.2.3