Boost C++ Libraries: Ticket #11014: Inconsistent use of BOOST_PP_VARIADICS_MSVC https://svn.boost.org/trac10/ticket/11014 <p> Clang generates multiple warnings of the form </p> <pre class="wiki">'BOOST_PP_VARIADICS_MSVC' is not defined, evaluates to 0 </pre><p> In <code>config/config.hpp</code>, <code>BOOST_PP_VARIADICS_MSVC</code> is either set to 1 or left undefined, but the following files test the <em>value</em> of <code>BOOST_PP_VARIADICS_MSVC</code>, triggering the above warning when the macro is undefined: </p> <pre class="wiki">seq/detail/binary_transform.hpp tuple/elem.hpp variadic/elem.hpp array/detail/get_data.hpp punctuation/is_begin_parens.hpp punctuation/detail/is_begin_parens.hpp facilities/is_empty_variadic.hpp facilities/detail/is_empty.hpp tuple/detail/is_single_return.hpp variadic/detail/is_single_return.hpp tuple/rem.hpp tuple/reverse.hpp tuple/size.hpp variadic/size.hpp list/to_array.hpp tuple/to_array.hpp variadic/to_array.hpp tuple/to_list.hpp tuple/to_seq.hpp test/tuple.cxx </pre><p> Suggested fix: change all the above to use <code>#ifdef</code> or <code>defined</code> to test the <em>existence</em> of <code>BOOST_PP_VARIADICS_MSVC</code> instead of the value. (A global replacement of <code>BOOST_PP_VARIADICS_MSVC</code> by <code>defined(BOOST_PP_VARIADICS_MSVC)</code> would be effective, if not elegant.) </p> <p> Alternate fix: change <code>config/config.hpp</code> so that <code>BOOST_PP_VARIADICS_MSVC</code> is either set to 1 or set to 0. In that case, the following files, which do currently test the existence of <code>BOOST_PP_VARIADICS_MSVC</code> (using <code>defined</code>), will need to be changed to test the value: </p> <pre class="wiki">test/facilities.cxx test/isempty_variadic_standard_failure.cxx test/isempty_variadic_standard_failure2.cxx test/isempty.cxx </pre> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/11014 Trac 1.4.3 Edward Diener Sun, 17 May 2015 04:47:32 GMT <link>https://svn.boost.org/trac10/ticket/11014#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11014#comment:1</guid> <description> <p> This has been fixed in the 'develop' branch of preprocessor library. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Edward Diener</dc:creator> <pubDate>Fri, 21 Aug 2015 13:50:39 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11014#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11014#comment:2</guid> <description> <p> This has now been fixed in the latest Boost 1.59 release. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Edward Diener</dc:creator> <pubDate>Fri, 21 Aug 2015 13:50:54 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/11014#comment:3 https://svn.boost.org/trac10/ticket/11014#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> Ticket