Boost C++ Libraries: Ticket #2738: at_thread_exit move overloading https://svn.boost.org/trac10/ticket/2738 <p> What do you think about adding move support for at_thread_exit? </p> <div class="wiki-code"><div class="code"><pre> <span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">F</span><span class="o">&gt;</span> <span class="kt">void</span> <span class="n">at_thread_exit</span><span class="p">(</span><span class="n">F</span><span class="o">&amp;&amp;</span> <span class="n">f</span><span class="p">);</span> </pre></div></div><p> and be emulated with the following prototypes? </p> <div class="wiki-code"><div class="code"><pre> <span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">F</span><span class="o">&gt;</span> <span class="kt">void</span> <span class="n">at_thread_exit</span><span class="p">(</span><span class="n">detail</span><span class="o">::</span><span class="n">thread_move_t</span><span class="o">&lt;</span><span class="n">F</span><span class="o">&gt;</span> <span class="n">f</span><span class="p">);</span> <span class="k">template</span><span class="o">&lt;</span><span class="k">typename</span> <span class="n">F</span><span class="o">&gt;</span> <span class="kt">void</span> <span class="n">at_thread_exit</span><span class="p">(</span><span class="n">F</span> <span class="n">f</span><span class="p">,</span> <span class="k">typename</span> <span class="n">disable_if</span><span class="o">&lt;</span><span class="n">boost</span><span class="o">::</span><span class="n">is_convertible</span><span class="o">&lt;</span><span class="n">F</span><span class="o">&amp;</span><span class="p">,</span><span class="n">detail</span><span class="o">::</span><span class="n">thread_move_t</span><span class="o">&lt;</span><span class="n">F</span><span class="o">&gt;</span> <span class="o">&gt;</span><span class="p">,</span> <span class="n">dummy</span><span class="o">*</span> <span class="o">&gt;::</span><span class="n">type</span><span class="o">=</span><span class="mi">0</span><span class="p">);</span> </pre></div></div><p> BTW, could you tell us why this function is not included on the C++0x proposal? </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/2738 Trac 1.4.3 viboes Fri, 11 Jun 2010 08:45:55 GMT status changed; resolution set https://svn.boost.org/trac10/ticket/2738#comment:1 https://svn.boost.org/trac10/ticket/2738#comment:1 <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">wontfix</span> </li> </ul> <p> This modification forces the function F to follow the specific Boost.Thread move semantics, which I don't think it is desirable. </p> <p> I think it will be better to wait until Boost.Thread replace its own move semantics by the one provided by Boost.Move (of course if accepted). </p> Ticket