Problem in short: How could one implement static if functionality, proposed in c++11, in plain c++ ?
static if
History and original prob
std::string a("hello world"); // bool a = true; if(std::is_same::value) { std::string &la = *(std::string*)&a; std::cout << "std::string " << la.c_str() << std::endl; } else { bool &la = *(bool*)&a; std::cout << "other type" << std::endl; }