Boost C++ Libraries: Ticket #13288: boost::apply_visitor compilation failure when used with inlined lambda transfering unique_ptr ownership https://svn.boost.org/trac10/ticket/13288 <p> Hi, </p> <p> I have a lambda that captures std::unique_ptr ownership by move on it's capture list and transfers is further. </p> <p> When such lambda is inlined in boost::apply_visitor function it failes to compile. I think it's connected with boost::apply_visitor template deduction . </p> <p> Wordaround is to create functor not and pass it to apply_visitor. </p> <p> Minimal example reproducing problem with boost 1.65 is includded as attachment and also can be found here: <a class="ext-link" href="http://coliru.stacked-crooked.com/a/955148fcc337290f"><span class="icon">​</span>http://coliru.stacked-crooked.com/a/955148fcc337290f</a> </p> <p> Compilation log is included as attachment. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/13288 Trac 1.4.3 Paweł Dac <pawel.dac@…> Mon, 06 Nov 2017 13:17:13 GMT attachment set https://svn.boost.org/trac10/ticket/13288 https://svn.boost.org/trac10/ticket/13288 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">boost_variant_apply_visitor_error.tar.gz</span> </li> </ul> <p> minimal problem example </p> Ticket Paweł Dac <pawel.dac@…> Mon, 06 Nov 2017 13:17:33 GMT attachment set https://svn.boost.org/trac10/ticket/13288 https://svn.boost.org/trac10/ticket/13288 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">boost_variant_apply_visitor_error.compilation.log</span> </li> </ul> <p> compilation log </p> Ticket Paweł Dac <pawel.dac@…> Mon, 06 Nov 2017 13:58:35 GMT severity changed https://svn.boost.org/trac10/ticket/13288#comment:1 https://svn.boost.org/trac10/ticket/13288#comment:1 <ul> <li><strong>severity</strong> <span class="trac-field-old">Cosmetic</span> → <span class="trac-field-new">Problem</span> </li> </ul> Ticket Antony Polukhin Wed, 28 Mar 2018 07:31:44 GMT owner, status, milestone changed https://svn.boost.org/trac10/ticket/13288#comment:2 https://svn.boost.org/trac10/ticket/13288#comment:2 <ul> <li><strong>owner</strong> changed from <span class="trac-author">ebf</span> to <span class="trac-author">Antony Polukhin</span> </li> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">assigned</span> </li> <li><strong>milestone</strong> <span class="trac-field-old">To Be Determined</span> → <span class="trac-field-new">Boost 1.67.0</span> </li> </ul> Ticket Antony Polukhin Wed, 28 Mar 2018 07:35:11 GMT <link>https://svn.boost.org/trac10/ticket/13288#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/13288#comment:3</guid> <description> <p> Fixed by Paweł Dac in <a class="ext-link" href="https://github.com/boostorg/variant/pull/40/commits/33784034b70a6607c9413633375e84912213a123"><span class="icon">​</span>33784034b70a6607c9413633375e84912213a123</a> </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Antony Polukhin</dc:creator> <pubDate>Wed, 28 Mar 2018 07:35:45 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/13288#comment:4 https://svn.boost.org/trac10/ticket/13288#comment:4 <ul> <li><strong>status</strong> <span class="trac-field-old">assigned</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> Ticket