[libgccjit] Wrap RETURN_NULL_IF_FAIL_NONNULL_NUMERIC_TYPE in JIT_{BEGIN,END}_STMT.
authorTom de Vries <tom@codesourcery.com>
Thu, 23 Nov 2017 15:03:48 +0000 (15:03 +0000)
committerTom de Vries <vries@gcc.gnu.org>
Thu, 23 Nov 2017 15:03:48 +0000 (15:03 +0000)
2017-11-23  Tom de Vries  <tom@codesourcery.com>

* libgccjit.c (RETURN_NULL_IF_FAIL_NONNULL_NUMERIC_TYPE): Wrap in
JIT_{BEGIN,END}_STMT.

From-SVN: r255101

gcc/jit/ChangeLog
gcc/jit/libgccjit.c

index 87b5473922abc2c6aa54ad30d688014278c567a9..35f210841163cb0df92977826105ac6094b26724 100644 (file)
@@ -1,3 +1,8 @@
+2017-11-23  Tom de Vries  <tom@codesourcery.com>
+
+       * libgccjit.c (RETURN_NULL_IF_FAIL_NONNULL_NUMERIC_TYPE): Wrap in
+       JIT_{BEGIN,END}_STMT.
+
 2017-10-31  David Malcolm  <dmalcolm@redhat.com>
 
        * docs/internals/index.rst (Running the test suite): Document
index c00acbfd81439409303e93212c21f2de01fe4e0d..8bad4f6481a0bf6c250899e13c700722c0548009 100644 (file)
@@ -1115,11 +1115,13 @@ gcc_jit_rvalue_get_type (gcc_jit_rvalue *rvalue)
    result of gcc_jit_context_get_type (GCC_JIT_TYPE_INT).  */
 
 #define RETURN_NULL_IF_FAIL_NONNULL_NUMERIC_TYPE(CTXT, NUMERIC_TYPE) \
+  JIT_BEGIN_STMT                                                    \
   RETURN_NULL_IF_FAIL (NUMERIC_TYPE, CTXT, NULL, "NULL type"); \
   RETURN_NULL_IF_FAIL_PRINTF1 (                                \
     NUMERIC_TYPE->is_numeric (), ctxt, NULL,                   \
     "not a numeric type: %s",                                  \
-    NUMERIC_TYPE->get_debug_string ());
+    NUMERIC_TYPE->get_debug_string ()); \
+  JIT_END_STMT
 
 /* Public entrypoint.  See description in libgccjit.h.