diff options
| author | Matthieu Sozeau | 2015-03-25 19:06:16 +0100 |
|---|---|---|
| committer | Matthieu Sozeau | 2015-03-25 19:11:45 +0100 |
| commit | 1bafb18f64ab1c929abfaf9c1b75f691914d9a46 (patch) | |
| tree | f62b8ec2d334d23f7214ec4805f05f748f04e0aa /kernel/nativelambda.ml | |
| parent | 5047734648d83890eb4fc4e5cff7ab77d46b48eb (diff) | |
Fix vm compiler to refuse to compile code making use of inductives with
more than 245 constructors (unsupported by OCaml's runtime).
Diffstat (limited to 'kernel/nativelambda.ml')
| -rw-r--r-- | kernel/nativelambda.ml | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/kernel/nativelambda.ml b/kernel/nativelambda.ml index 543397df53..383f810295 100644 --- a/kernel/nativelambda.ml +++ b/kernel/nativelambda.ml @@ -375,9 +375,12 @@ let makeblock env cn u tag args = let rec get_allias env (kn, u as p) = let tps = (lookup_constant kn env).const_body_code in - match Cemitcodes.force tps with - | Cemitcodes.BCallias kn' -> get_allias env kn' - | _ -> p + match tps with + | None -> p + | Some tps -> + match Cemitcodes.force tps with + | Cemitcodes.BCallias kn' -> get_allias env kn' + | _ -> p (*i Global environment *) |
