c++11 - How to enable C++ multithreading? -


i've been trying multithreaded c++. installed new dev c++ 5.4.1 , added -std=c++11 compiler options. added #include <thread> somewhere in source code, , std::thread mythread (some_func).

when compile source file, compiler error "thread defined in scope".

what have have working?

official build of mingw (that compiler dev-c++ uses) has no support standard library threads now.

you can use boost::thread drop in replacement (api similiar enough) or use microsoft visual c++, or try programming g++ on linux (this have done recently, using virtual machine).


Comments

Popular posts from this blog

Winapi c++: DialogBox hangs when breaking a loop -

vb.net - Font adding using PDFsharp -

javascript - jQuery iScroll clickable list elements while retaining scroll? -