[ocaml] Rename value in bools.i to avoid clash

The ocaml headers have a value typedef.

See #2649
This commit is contained in:
Olly Betts 2023-07-06 10:03:26 +12:00
parent 22691b76a6
commit 5a11b14bf0
1 changed files with 7 additions and 1 deletions

View File

@ -5,6 +5,12 @@
%rename(BoolSt) BoolStructure;
#endif
/* We had to rename this in the C++ API being wrapped due to a collision with
* a value typedef in newer ocaml headers, so use %rename to avoid having to
* update all the runme files which use it.
*/
%rename(value) bool_value;
%warnfilter(SWIGWARN_TYPEMAP_SWIGTYPELEAK); /* memory leak when setting a ptr/ref variable */
%warnfilter(SWIGWARN_RUBY_WRONG_NAME) constbool; /* Ruby, wrong class name */
@ -44,7 +50,7 @@ const bool* const_pbo(const bool* b) {
}
// helper function
bool value(bool* b) {
bool bool_value(bool* b) {
return *b;
}