It's impossible to support this exact syntax (all 4 forms at the same time).
The closest thing I can think of is:
template <auto V = 0>struct Example {};
Example<int(1)> a; // Type and value.Example<int{}> a; // Type only.Example a; // Neither.Example<1> a; // Value only.