diff options
| author | barras | 2002-01-16 14:39:14 +0000 |
|---|---|---|
| committer | barras | 2002-01-16 14:39:14 +0000 |
| commit | 3ec3c28ef7cab6ea7efc9552be585d48583c51cb (patch) | |
| tree | 4655d8e751150594491f4bb11a077b69d03db094 /kernel/indtypes.ml | |
| parent | efa366d8d72392735872d2a74c47d804c93e6450 (diff) | |
correction de bug avec les mutuels imbriques a plusieurs niveaux
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@2401 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'kernel/indtypes.ml')
| -rw-r--r-- | kernel/indtypes.ml | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/kernel/indtypes.ml b/kernel/indtypes.ml index a5224914ba..6ea71e09a5 100644 --- a/kernel/indtypes.ml +++ b/kernel/indtypes.ml @@ -337,8 +337,11 @@ let listrec_mconstr env ntypes hyps nparams i indlc = else raise (IllFormedInd (LocalNonPos n)) | Ind ind_sp -> - if List.for_all (noccur_between n ntypes) largs - then Norec + (* If the inductive type being defined or a parameter appears as + parameter, then we have an imbricated type *) + if List.for_all (noccur_between n ntypes) largs && + List.for_all (noccur_between (n-nhyps) nhyps) largs + then Norec else Imbr(ind_sp,imbr_positive env n ind_sp largs) | err -> if noccur_between n ntypes x && |
