奇怪的C ++成员函数声明语法:&&预选赛

时间:2010-02-22 11:54:52

标签: c++ boost-thread

来自Boost::Thread

template <typename R>
class shared_future
{
...
// move support
shared_future(shared_future && other);
shared_future(unique_future<R> && other);
shared_future& operator=(shared_future && other);
shared_future& operator=(unique_future<R> && other);
...
}

这些双括号究竟是什么?我浏览了“BS C ++ Langauge 3d版”并找不到任何解释。

1 个答案:

答案 0 :(得分:6)

这是rvalue引用的C ++ 0x附加。

请参阅http://www.artima.com/cppsource/rvalue.html

相关问题