c++0x, std::thread error

luís lmsilva@gmx.de
Fri Mar 26 00:55:00 GMT 2010


Hello
I compiled & installed gcc4.4 using macports.
When I try to compile:
	
	#include <thread>
	...
		std::thread t(handle);
		t.join();
	....
the compiler returns:
	cserver.cpp: In member function 'int CServer::run()':
	cserver.cpp:48: error: 'thread' is not a member of 'std'
	cserver.cpp:48: error: expected ';' before 't'
	cserver.cpp:49: error: 't' was not declared in this scope

std::cout <<... works fine.

Can anyone help me?

Thanks!



More information about the Gcc-help mailing list