
21 Mar
2011
21 Mar
'11
4:37 p.m.
On Mon, 21 Mar 2011 02:27:17 +0100, 乔志强
It is only boost::thread
int foo() { this_thread::sleep(seconds(1000)); return 0; }
int main(int argc, char** argv) { boost::packaged_task<int> pt(&foo);
boost::unique_future<int> fi = pt.get_future(); ..........................
The problem is reproducible with gcc 4.4.5 and boost 1.46.1 on ubuntu x86 linux. I'd classify the issue as a boost bug and submit it into tracker unless somebody from boost::future knowers clarify the situation. -- Slava