fork(4) download
  1. #include <iostream>
  2. void fun(int*)=delete;
  3. void fun(double)=delete;
  4. void fun(char)=delete;
  5. void fun(unsigned)=delete;
  6. void fun(float)=delete;
  7. void fun(long int);
  8. int main()
  9. {
  10. fun(3);
  11. }
  12. void fun(long int a)
  13. {
  14. std::cout<<a<<'\n';
  15. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In function 'int main()':
prog.cpp:10:7: error: call of overloaded 'fun(int)' is ambiguous
  fun(3);
       ^
prog.cpp:3:6: note: candidate: void fun(double) <deleted>
 void fun(double)=delete;
      ^
prog.cpp:4:6: note: candidate: void fun(char) <deleted>
 void fun(char)=delete;
      ^
prog.cpp:5:6: note: candidate: void fun(unsigned int) <deleted>
 void fun(unsigned)=delete;
      ^
prog.cpp:6:6: note: candidate: void fun(float) <deleted>
 void fun(float)=delete;
      ^
prog.cpp:7:6: note: candidate: void fun(long int)
 void fun(long int);
      ^
stdout
Standard output is empty