Issue with std::thread from c++11
问题 I have some troubles trying to compile a program with multi-threading from the standard template library. It return me a obscure error when i try to compile the following program : #include <iostream> #include <thread> void foo() { std::cout << "Thread 1\n"; } int main(int argc, char** argv) { std::thread tr(foo); std::cout << "Main thread\n"; tr.join(); return 0; } I don't understand the error : /tmp/ccE8EtL1.o : In the function « std::thread::thread<void (&)()>(void (&)()) » : file.cpp:(