diff options
| author | Arnaud Spiwack | 2015-03-13 15:43:12 +0100 |
|---|---|---|
| committer | Arnaud Spiwack | 2015-03-13 16:41:03 +0100 |
| commit | 494ab7773515ea67bf365707852bbb4074f866ba (patch) | |
| tree | 859bb794a729955db53bfade584bc647f0f507ab /kernel/byterun/coq_fix_code.c | |
| parent | edb3302188af4b5b75111339e3f466a6ec09aef2 (diff) | |
Fix compilation with forthcoming Ocaml version 4.03.
Backported from a patch for v8.4 by Pierre Chambart. Part of the commit has been rendered obsolete by code reorganisation, leaving:
* OCaml runtime header files used to declare the int32, uint32, int64
and uint64 type. That got removed, and uses of those types should be replaced by the standard ones: uint32_t, int32_t, int64_t, uint64_t. Those are defined in stdint.h.
Diffstat (limited to 'kernel/byterun/coq_fix_code.c')
| -rw-r--r-- | kernel/byterun/coq_fix_code.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/kernel/byterun/coq_fix_code.c b/kernel/byterun/coq_fix_code.c index 3fded66385..52dc49bf8e 100644 --- a/kernel/byterun/coq_fix_code.c +++ b/kernel/byterun/coq_fix_code.c @@ -13,6 +13,7 @@ #include <stdio.h> #include <stdlib.h> +#include <stdint.h> #include <caml/config.h> #include <caml/misc.h> #include <caml/mlvalues.h> @@ -146,7 +147,7 @@ value coq_tcode_of_code (value code, value size) { }; *q++ = VALINSTR(instr); if (instr == SWITCH) { - uint32 i, sizes, const_size, block_size; + uint32_t i, sizes, const_size, block_size; COPY32(q,p); p++; sizes=*q++; const_size = sizes & 0xFFFF; @@ -154,13 +155,13 @@ value coq_tcode_of_code (value code, value size) { sizes = const_size + block_size; for(i=0; i<sizes; i++) { COPY32(q,p); p++; q++; }; } else if (instr == CLOSUREREC || instr==CLOSURECOFIX) { - uint32 i, n; + uint32_t i, n; COPY32(q,p); p++; /* ndefs */ n = 3 + 2*(*q); /* ndefs, nvars, start, typlbls,lbls*/ q++; for(i=1; i<n; i++) { COPY32(q,p); p++; q++; }; } else { - uint32 i, ar; + uint32_t i, ar; ar = arity[instr]; for(i=0; i<ar; i++) { COPY32(q,p); p++; q++; }; } |
