fork download
  1. struct Foo
  2. {
  3. explicit Foo(int x) : x_(x) {}
  4. int x_;
  5. };
  6.  
  7. int main()
  8. {
  9. Foo(1) == Foo(1);
  10. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In function 'int main()':
prog.cpp:9:9: error: no match for 'operator==' (operand types are 'Foo' and 'Foo')
  Foo(1) == Foo(1);
         ^
stdout
Standard output is empty