How to select the method at compilation time?
I remember reading some article using new C++ features to implement the
selection at compiler time but cannot figure out how to do it. For
example, I have a method doing the following
template<class T>
void foo()
{
if (std::is_abstract<T>::value)
do something;
else
do others.
}
No comments:
Post a Comment