#include<thread>
#include<iostream>
using namespace std;
class Test{
public:
void say(){
cout<< "hello c++11" <<endl;
}
static void startThread(){
thread th(bind(&Test::say,Test::Instance()));
th.join();
}
static Test* Instance(){
static Test t;
return &t;
}
protected:
Test(){}
};
int main()
{
Test::startThread();
return 0;
}