fork download
  1.  
  2. template <typename T>
  3. class TD;
  4.  
  5. template<typename T>
  6. void f(T _t)
  7. {
  8. TD<T> a{};
  9. }
  10.  
  11. int main() {
  12. const int& i = 3;
  13. f(i);
  14. return 0;
  15. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In instantiation of 'void f(T) [with T = int]':
prog.cpp:13:5:   required from here
prog.cpp:8:10: error: 'TD<int> a' has incomplete type
  TD<T> a{};
          ^
stdout
Standard output is empty