Here you mix two different approaches. The first is the proposal suggested by @KerrekSB
template<typename T, bool B = is_fundamental<T>::value> class class_name;
Alternatively, you can completely write a generic class template and explicitly set a static member for <string, false>
template<typename T, bool B = is_fundamental<T>::value> class class_name { public: static string const value; };
TemplateRex
source share