fork download
  1. #include <string>
  2. class A
  3. {
  4. public:
  5. template<class T>
  6. static T& Get(const std::wstring&);
  7. };
  8.  
  9. class B
  10. {
  11. public:
  12. void f(
  13. double d,
  14. double c = A::Get<double>(L"test"));
  15. };
  16.  
  17. int main()
  18. {
  19. B b;
  20. b.f(5);
  21. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
/home/PsreXn/cccgko8t.o: In function `main':
prog.cpp:(.text.startup+0x28): undefined reference to `double& A::Get<double>(std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> > const&)'
prog.cpp:(.text.startup+0x3e): undefined reference to `B::f(double, double)'
collect2: error: ld returned 1 exit status
stdout
Standard output is empty