fork download
  1. struct Foo
  2. {
  3. explicit Foo(int a):m(a){}
  4. int padd1, m, padd2;
  5. };
  6.  
  7. void Bar(Foo){}
  8.  
  9. int main()
  10. {
  11. //Bar(11); // OK, gives error
  12. auto x = static_cast<Foo>(37);
  13. x.m;
  14. }
Success #stdin #stdout 0s 3408KB
stdin
Standard input is empty
stdout
Standard output is empty