diff --git a/llvm/bindings/ocaml/bitreader/bitreader_ocaml.c b/llvm/bindings/ocaml/bitreader/bitreader_ocaml.c index b154f68d6099..0fd484f12343 100644 --- a/llvm/bindings/ocaml/bitreader/bitreader_ocaml.c +++ b/llvm/bindings/ocaml/bitreader/bitreader_ocaml.c @@ -37,6 +37,9 @@ static void llvm_raise(value Prototype, char *Message) { raise_with_arg(Prototype, CamlMessage); abort(); /* NOTREACHED */ +#ifdef CAMLnoreturn + CAMLnoreturn; /* Silences warnings, but is missing in some versions. */ +#endif } diff --git a/llvm/bindings/ocaml/executionengine/executionengine_ocaml.c b/llvm/bindings/ocaml/executionengine/executionengine_ocaml.c index 58d7d5a77f66..0f124c546eeb 100644 --- a/llvm/bindings/ocaml/executionengine/executionengine_ocaml.c +++ b/llvm/bindings/ocaml/executionengine/executionengine_ocaml.c @@ -43,6 +43,9 @@ static void llvm_raise(value Prototype, char *Message) { raise_with_arg(Prototype, CamlMessage); abort(); /* NOTREACHED */ +#ifdef CAMLnoreturn + CAMLnoreturn; /* Silences warnings, but is missing in some versions. */ +#endif } diff --git a/llvm/bindings/ocaml/llvm/llvm_ocaml.c b/llvm/bindings/ocaml/llvm/llvm_ocaml.c index 5c8767543f22..3f48887e11f4 100644 --- a/llvm/bindings/ocaml/llvm/llvm_ocaml.c +++ b/llvm/bindings/ocaml/llvm/llvm_ocaml.c @@ -45,6 +45,9 @@ static void llvm_raise(value Prototype, char *Message) { raise_with_arg(Prototype, CamlMessage); abort(); /* NOTREACHED */ +#ifdef CAMLnoreturn + CAMLnoreturn; /* Silences warnings, but is missing in some versions. */ +#endif }