https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65291

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |diagnostic

--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> ---
Reduced:

struct A {
  A(int a = 0) { }
};

struct B : A {
  using A::A;
  B(int, int);
};

B b;


FWIW the relevant output from Clang trunk is:

c.cc:10:3: error: no matching constructor for initialization of 'B'
B b;
  ^
c.cc:6:12: note: candidate constructor (inherited) not viable: requires 1
argument, but 0 were provided
  using A::A;
           ^
c.cc:2:3: note: inherited from here
  A(int a = 0) { }
  ^


EDG says simply:

"c.cc", line 10: error: no default constructor exists for class "B"
  B b;
    ^

Reply via email to