Boost C++ Libraries: Ticket #11682: fusion::pair not compatible with std::is_default_constructible https://svn.boost.org/trac10/ticket/11682 <p> When the <code>Second</code> type of pair is not default constructible, <code>std::is_default_constructible</code> either returns true or fails to compile for fusion::pair. </p> <p> This is on OSX with apple and macports compilers. </p> <p> Adding <code>enable_if&lt; is_default_constructible&lt;Second&gt; &gt;</code> to pair's default constructor makes this work as expected. </p> <pre class="wiki">struct NotDefaultConstructible { NotDefaultConstructible(int){}; }; // prints 0 std::cout &lt;&lt; std::is_default_constructible&lt; NotDefaultConstructible &gt;::value &lt;&lt; std::endl; using fusion_pair1 = boost::fusion::pair&lt;int, NotDefaultConstructible&gt;; // should print 0 // fails to compile on clang (xcode 7, 3.4, 3.6, 3.7), gcc 4.9 // prints 1 on gcc 5, clang 3.4 std::cout &lt;&lt; std::is_default_constructible&lt; fusion_pair1 &gt;::value &lt;&lt; std::endl; </pre><p> Test and patch attached. Patch is unlikely to meat portability requirements to be applied as-is. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/11682 Trac 1.4.3 crmoore@… Thu, 24 Sep 2015 14:59:59 GMT attachment set https://svn.boost.org/trac10/ticket/11682 https://svn.boost.org/trac10/ticket/11682 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">test-11681.cpp</span> </li> </ul> <p> Test app </p> Ticket crmoore@… Thu, 24 Sep 2015 15:00:22 GMT attachment set https://svn.boost.org/trac10/ticket/11682 https://svn.boost.org/trac10/ticket/11682 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">patch1-11681.patch</span> </li> </ul> Ticket