roboptim-core
roboptim-core copied to clipboard
Clang & Boost Test: "empty macro arguments are a C99 feature"
With Boost 1.56 and clang 3.5.0, I get the following error:
.../roboptim-core/tests/shared-tests/fixture.hh:46:5: error: empty macro arguments are a C99 feature [-Werror,-Wc99-extensions]
BOOST_REQUIRE_EQUAL (lt_dlsetsearchpath (PLUGIN_PATH), 0);
^
/usr/include/boost/test/test_tools.hpp:171:5: note: expanded from macro 'BOOST_REQUIRE_EQUAL'
BOOST_CHECK_WITH_ARGS_IMPL( ::boost::test_tools::tt_detail::equal_impl_frwd(), "", REQUIRE, CHECK_EQUAL, (L)(R) )
...
/usr/include/boost/preprocessor/variadic/elem.hpp:26:101: note: expanded from macro 'BOOST_PP_VARIADIC_ELEM'
# define BOOST_PP_VARIADIC_ELEM(n, ...) BOOST_PP_CAT(BOOST_PP_VARIADIC_ELEM_, n)(__VA_ARGS__,)
^
It seems to be a known issue:
- http://boost.2283326.n4.nabble.com/clang-and-variadic-macro-warnings-revisited-td4666475.html
- http://comments.gmane.org/gmane.comp.compilers.clang.devel/38486
There's not much we can do, except enable C99 extensions.
I guess that popping the warning for this clang version makes sense then.