fork download
  1. template <typename = void> void f() {
  2. return 0;
  3. }
  4.  
  5. template void f();
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In function 'void f() [with <template-parameter-1-1> = void]':
prog.cpp:5:18:   instantiated from here
prog.cpp:2:12: error: return-statement with a value, in function returning 'void'
stdout
Standard output is empty