diff options
| author | coq | 2002-09-30 12:17:42 +0000 |
|---|---|---|
| committer | coq | 2002-09-30 12:17:42 +0000 |
| commit | 6e5084efe14cedde600dffccf9645dadb059199a (patch) | |
| tree | 25103f29078579d8c29137267d9333bfc64af2a6 /kernel/subtyping.ml | |
| parent | e130e05625e926c5debfa223462efd8f42b766fe (diff) | |
Comparaisons des types pendant le sous-typage reactive
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@3052 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'kernel/subtyping.ml')
| -rw-r--r-- | kernel/subtyping.ml | 27 |
1 files changed, 6 insertions, 21 deletions
diff --git a/kernel/subtyping.ml b/kernel/subtyping.ml index fa024b7f25..2a81ebee0b 100644 --- a/kernel/subtyping.ml +++ b/kernel/subtyping.ml @@ -156,32 +156,17 @@ let check_constant cst env msid1 l info1 cb2 spec2 = | _ -> error () in assert (cb1.const_hyps=[] && cb2.const_hyps=[]) ; - (*Start by checking bodies*) + (*Start by checking types*) + let cst = check_conv cst conv_leq env cb1.const_type cb2.const_type in match cb2.const_body with - | None -> check_conv cst conv_leq env cb1.const_type cb2.const_type - | Some c2 -> (* no checking types ! *) + | None -> cst + | Some c2 -> let c1 = match cb1.const_body with - | None -> mkConst (make_kn (MPself msid1) empty_dirpath l) | Some c1 -> c1 + | None -> mkConst (make_kn (MPself msid1) empty_dirpath l) in check_conv cst conv env c1 c2 - -(* (*Start by checking types*) - let cst = check_conv cst conv_leq env cb1.const_type cb2.const_type in - match cb1.const_body, cb2.const_body with - | None, None -> cst - | Some _, None -> cst - | Some c1, Some c2 -> - check_conv cst conv env c1 c2 - | None, Some c2 -> - check_conv - cst - conv - env - (mkConst (make_kn (MPself msid1) empty_dirpath l)) - c2 -*) - + let rec check_modules cst env msid1 l (mtb1,mpo1,cst1 as msb1) (mtb2,mpo2,cst2 as msb2) = let mp = (MPdot(MPself msid1,l)) in |
