aboutsummaryrefslogtreecommitdiff
path: root/kernel/modops.ml
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/modops.ml')
-rw-r--r--kernel/modops.ml4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/modops.ml b/kernel/modops.ml
index 7459dcad8d..569580bfb1 100644
--- a/kernel/modops.ml
+++ b/kernel/modops.ml
@@ -125,12 +125,12 @@ let rec check_modpath_equiv env mp1 mp2 =
let rec subst_modtype sub = function
| MTBident ln -> MTBident (subst_kn sub ln)
| MTBfunsig (arg_id, arg_b, body_b) ->
- assert (not (occur_mbid arg_id sub));
+ if occur_mbid arg_id sub then failwith "capture";
MTBfunsig (arg_id,
subst_modtype sub arg_b,
subst_modtype sub body_b)
| MTBsig (sid1, msb) ->
- assert (not (occur_msid sid1 sub));
+ if occur_msid sid1 sub then failwith "capture";
MTBsig (sid1, subst_signature sub msb)
and subst_signature sub sign =