Imported Upstream version 1.72.0
[platform/upstream/boost.git] / boost / spirit / home / classic / core / assert.hpp
index 47b1b39..f4fee1d 100644 (file)
@@ -26,8 +26,8 @@
 #elif defined (BOOST_SPIRIT_ASSERT_EXCEPTION)
     #define BOOST_SPIRIT_ASSERT_AUX(f, l, x) BOOST_SPIRIT_ASSERT_AUX2(f, l, x)
     #define BOOST_SPIRIT_ASSERT_AUX2(f, l, x)                                   \
-    do{ if (!(x)) boost::throw_exception(                                       \
-        BOOST_SPIRIT_ASSERT_EXCEPTION(f "(" #l "): " #x)); } while(0)
+    ( (x) ? (void)0 : boost::throw_exception(                                   \
+        BOOST_SPIRIT_ASSERT_EXCEPTION(f "(" #l "): " #x)) )
     #define BOOST_SPIRIT_ASSERT(x) BOOST_SPIRIT_ASSERT_AUX(__FILE__, __LINE__, x)
 #else
     #include <boost/assert.hpp>