C++ examples for boost:thread
Creating a Thread using boot library
#include <iostream> #include <boost/thread/thread.hpp> #include <boost/thread/xtime.hpp> struct MyThreadFunc { void operator()() { } } threadFun; int main() { boost::thread myThread(threadFun); boost::thread::yield(); myThread.join(); }