fork download
  1. struct A {
  2. int x;
  3. A(unsigned x) : x(x) {}
  4. };
  5.  
  6. struct B : A
  7. {
  8. B() : A(7) {}
  9. };
  10.  
  11. int main()
  12. {
  13. A *a = new B();
  14. delete a;
  15.  
  16. return 0;
  17. }
Success #stdin #stdout 0s 4180KB
stdin
Standard input is empty
stdout
Standard output is empty