Do you see why the static_assert fail:
template <typename T>
void
foo(const T &c)
{
static_assert(std::is_base_of<T, char>::value, "T must be char"); // Fails !
}
int main()
{
char c = 'a';
foo<char>(c);
return 0;
}
I swapped T and "char", still fails.