Avoid multiple declarations in generated .c files in -output-obj
authorStephane Glondu <steph@glondu.net>
Thu, 21 Apr 2011 16:39:31 +0000 (18:39 +0200)
committerStéphane Glondu <glondu@debian.org>
Tue, 6 Aug 2019 07:27:23 +0000 (09:27 +0200)
commit1f5ab4449a075caeaf075da4a5535281feee9610
treeb473b131e874fdaa219bae7dbbede25e2380a1d5
parentf112f9ec50e5e870abacda3394ae7a9e24198f65
Avoid multiple declarations in generated .c files in -output-obj

In -output-obj mode, <caml/mlvalues.h> (which contains some
primitives) is included in the generated .c file, leading to errors
when compiling with g++ (multiple declarations).

There are probably better implementations (in particular, in this one,
care must be taken when changing the list of primitives available in
mlvalues.h), but this is a small and (not too) intrusive patch.

Bug: http://caml.inria.fr/mantis/view.php?id=5254
Signed-off-by: Stephane Glondu <steph@glondu.net>
Gbp-Pq: Name 0005-Avoid-multiple-declarations-in-generated-.c-files-in.patch
bytecomp/bytelink.ml
bytecomp/symtable.ml
bytecomp/symtable.mli