aboutsummaryrefslogtreecommitdiff
path: root/kernel/cbytegen.ml
diff options
context:
space:
mode:
authorEmilio Jesus Gallego Arias2018-05-21 21:48:00 +0200
committerEmilio Jesus Gallego Arias2018-09-24 15:27:18 +0200
commit2cceef0e3cab18b1dcc28bf1c8ce6b4723cd3d9a (patch)
tree2b584a747ffca2f18c96a81b2498ef82a3e3348d /kernel/cbytegen.ml
parentc2a1cc7473cf4db27ee47ac011409f7a1839b36d (diff)
[kernel] Compile with almost all warnings enabled.
This is a partial resurrection of #6423 but only for the kernel. IMHO, we pay a bit of price for this but it is a good safety measure. Only warning "4: fragile pattern matching" and "44: open hides a type" are disabled. We would like to enable 44 for sure once we do some alias cleanup.
Diffstat (limited to 'kernel/cbytegen.ml')
-rw-r--r--kernel/cbytegen.ml8
1 files changed, 4 insertions, 4 deletions
diff --git a/kernel/cbytegen.ml b/kernel/cbytegen.ml
index 5362f9a814..73620ae578 100644
--- a/kernel/cbytegen.ml
+++ b/kernel/cbytegen.ml
@@ -413,7 +413,7 @@ let code_makeblock ~stack_size ~arity ~tag cont =
Kpush :: nest_block tag arity cont
end
-let compile_structured_constant cenv sc sz cont =
+let compile_structured_constant _cenv sc sz cont =
set_max_stack_size sz;
Kconst sc :: cont
@@ -534,7 +534,7 @@ let rec compile_lam env cenv lam sz cont =
comp_app compile_structured_constant compile_get_univ cenv
(Const_sort (Sorts.Type u)) (Array.of_list s) sz cont
- | Llet (id,def,body) ->
+ | Llet (_id,def,body) ->
compile_lam env cenv def sz
(Kpush ::
compile_lam env (push_local sz cenv) body (sz+1) (add_pop 1 cont))
@@ -561,7 +561,7 @@ let rec compile_lam env cenv lam sz cont =
| _ -> comp_app (compile_lam env) (compile_lam env) cenv f args sz cont
end
- | Lfix ((rec_args, init), (decl, types, bodies)) ->
+ | Lfix ((rec_args, init), (_decl, types, bodies)) ->
let ndef = Array.length types in
let rfv = ref empty_fv in
let lbl_types = Array.make ndef Label.no in
@@ -594,7 +594,7 @@ let rec compile_lam env cenv lam sz cont =
(Kclosurerec(fv.size,init,lbl_types,lbl_bodies) :: cont)
- | Lcofix(init, (decl,types,bodies)) ->
+ | Lcofix(init, (_decl,types,bodies)) ->
let ndef = Array.length types in
let lbl_types = Array.make ndef Label.no in
let lbl_bodies = Array.make ndef Label.no in