prog.cpp:28:1: error: explicit template specialization cannot have a storage class
static int setupTempl<2>(int a, int b)
^~~~~~
prog.cpp: In function ‘int setupTempl(int, int) [with int N = 3]’:
prog.cpp:36:27: error: too many arguments to function ‘int foo(int, int)’
return foo(a, b, true);
^
prog.cpp:4:5: note: declared here
int foo(int a, int b)
^~~
prog.cpp: At global scope:
prog.cpp:34:1: error: explicit template specialization cannot have a storage class
static int setupTempl<3>(int a, int b)
^~~~~~