Boost C++ Libraries: Ticket #8740: Possibly invalid assertion in define_with_defaults() https://svn.boost.org/trac10/ticket/8740 <p> Hi there, </p> <p> this assertion in <code>boost/python/detail/defaults_def.hpp</code> seems backwards: </p> <pre class="wiki">BOOST_STATIC_ASSERT( (stubs_type::max_args) &lt;= mpl::size&lt;SigT&gt;::value); </pre><p> I.e. I would expect the assertion to be that the actual number of arguments is *smaller* than the max or *larger* than the min. </p> <p> It caused me a compile error like the following on gcc 4.8: </p> <pre class="wiki">In file included from /usr/include/boost/python/overloads.hpp:11:0, from /usr/include/boost/python.hpp:52, from src/wrapper/common.hpp:24, from src/wrapper/id3.cpp:40: /usr/include/boost/python/detail/defaults_def.hpp: In instantiation of ‘void boost::python::detail::define_with_defaults(const char*, const OverloadsT&amp;, NameSpaceT&amp;, const SigT&amp;) [with OverloadsT = {anonymous}::render_overloads; NameSpaceT = boost::python::class_&lt;TagLib::ID3v2::Tag, boost::noncopyable_::noncopyable, boost::python::bases&lt;TagLib::Tag&gt; &gt;; SigT = boost::mpl::vector2&lt;TagLib::ByteVector, TagLib::ID3v2::Tag&amp;&gt;]’: /usr/include/boost/python/class.hpp:598:9: required from ‘void boost::python::class_&lt;T, X1, X2, X3&gt;::def_maybe_overloads(const char*, SigT, const OverloadsT&amp;, const boost::python::detail::overloads_base*) [with OverloadsT = {anonymous}::render_overloads; SigT = TagLib::ByteVector (TagLib::ID3v2::Tag::*)()const; W = TagLib::ID3v2::Tag; X1 = boost::noncopyable_::noncopyable; X2 = boost::python::bases&lt;TagLib::Tag&gt;; X3 = boost::python::detail::not_specified]’ /usr/include/boost/python/class.hpp:245:9: required from ‘boost::python::class_&lt;T, X1, X2, X3&gt;::self&amp; boost::python::class_&lt;T, X1, X2, X3&gt;::def(const char*, A1, const A2&amp;) [with A1 = TagLib::ByteVector (TagLib::ID3v2::Tag::*)()const; A2 = {anonymous}::render_overloads; W = TagLib::ID3v2::Tag; X1 = boost::noncopyable_::noncopyable; X2 = boost::python::bases&lt;TagLib::Tag&gt;; X3 = boost::python::detail::not_specified; boost::python::class_&lt;T, X1, X2, X3&gt;::self = boost::python::class_&lt;TagLib::ID3v2::Tag, boost::noncopyable_::noncopyable, boost::python::bases&lt;TagLib::Tag&gt; &gt;]’ src/wrapper/id3.cpp:221:8: required from here /usr/include/boost/python/detail/defaults_def.hpp:247:1: error: invalid application of ‘sizeof’ to incomplete type ‘boost::STATIC_ASSERTION_FAILURE&lt;false&gt;’ </pre> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/8740 Trac 1.4.3 Andreas Kloeckner <inform@…> Thu, 27 Jun 2013 16:06:37 GMT cc set https://svn.boost.org/trac10/ticket/8740#comment:1 https://svn.boost.org/trac10/ticket/8740#comment:1 <ul> <li><strong>cc</strong> <span class="trac-author">inform@…</span> added </li> </ul> Ticket