3

来自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 The C++ Langauge 3d edition”,但找不到任何解释。

4

1 回答 1

6

这是针对右值引用的 C++0x 添加。

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

于 2010-02-22T11:56:39.583 回答