Boost C++ Libraries: Ticket #11269: Fusion adapting an "empty" struct is no longer possible in boost 1.58 https://svn.boost.org/trac10/ticket/11269 <p> The following examples fails to compile with boost 1.58 with -std=c++11, but does compile with 1.57 (and -std=c++11). If you test the code with the 1.58 release you need to add the -DBOOST_NO_CXX11_CONSTEXPR flag to workaround <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/11211" title="#11211: Bugs: Fusion example no longer compiles (BOOST_FUSION_DEFINE_STRUCT) (closed: fixed)">#11211</a> </p> <pre class="wiki">#include &lt;boost/fusion/adapted/struct.hpp&gt; struct X {}; BOOST_FUSION_ADAPT_STRUCT( X, ) int main() { return 0; } </pre> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/11269 Trac 1.4.3 damien.buhl@… Wed, 06 May 2015 05:26:30 GMT <link>https://svn.boost.org/trac10/ticket/11269#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11269#comment:1</guid> <description> <p> We did not had this usage in our testcases and I didn't even thought about it as an interesting use of adapt struct. </p> <p> I understand however now that one might want to do this. I'm looking at it, I might fix this fast. </p> </description> <category>Ticket</category> </item> <item> <author>damien.buhl@…</author> <pubDate>Wed, 06 May 2015 05:41:34 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11269#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11269#comment:2</guid> <description> <p> There is a workaround for your issue until I get it fixed. Compile with the following flag disabled: </p> <p> g++ -DBOOST_PP_VARIADICS=0 main.cpp </p> <p> This will take the code path using sequences only which works as in 1.57. I'm still fixing the other case however. </p> </description> <category>Ticket</category> </item> <item> <author>damien.buhl@…</author> <pubDate>Wed, 06 May 2015 06:33:31 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11269#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11269#comment:3</guid> <description> <p> So I have a fix working and passing all tests + this new test case with or without VARIADICS enabled. </p> <p> Is there other use case than ADAPT_STRUCT with empty struct ? Do you think ADAPT_ADT might also be needed with empty struct ? ASSOC_STRUCT? </p> <p> djowel can you remember which use cases might makes sense ? </p> <p> The fix is for the moment in my branch on github : daminetreg/fusion branch : feature/fix-ticket-11269-adapt-empty-struct </p> <p> I also made a PR for it in github boostorg/fusion<a class="closed ticket" href="https://svn.boost.org/trac10/ticket/75" title="#75: Bugs: Solaris - once.cpp compile error (closed: wontfix)">#75</a> </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Joel de Guzman</dc:creator> <pubDate>Wed, 06 May 2015 07:37:55 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11269#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11269#comment:4</guid> <description> <p> We should probably support all cases of empy structs/classes. it's kind wiered with ADAPT_ADT, but i can't tell when someone will use such a thing. maybe in generic code? </p> </description> <category>Ticket</category> </item> <item> <author>damien.buhl@…</author> <pubDate>Fri, 15 May 2015 07:22:09 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11269#comment:5 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11269#comment:5</guid> <description> <p> Happily since my PR <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/75" title="#75: Bugs: Solaris - once.cpp compile error (closed: wontfix)">#75</a> we do support all cases of empty structs/classes. I made a new PR <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/76" title="#76: Bugs: invalid result for File Dependency Examp (closed: Fixed)">#76</a> with all the testcases. </p> <p> This bug is fixed. :) </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Joel de Guzman</dc:creator> <pubDate>Fri, 12 Jun 2015 06:50:51 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/11269#comment:6 https://svn.boost.org/trac10/ticket/11269#comment:6 <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