https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63374
Eric Gallager <egallager at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2017-08-21
CC| |egallager at gcc dot gnu.org
Ever confirmed|0 |1
--- Comment #1 from Eric Gallager <egallager at gcc dot gnu.org> ---
Confirmed, the output I get is:
$ /usr/local/bin/g++ -c -Wall -Wextra -pedantic -Wmissing-field-initializers
-Weffc++ 63374.cc
63374.cc: In constructor ‘A::A(int)’:
63374.cc:16:2: warning: ‘A::a1’ should be initialized in the member
initialization list [-Weffc++]
A(int x) : b1(x), b2(x), b3(x), b4(x) {}
^
63374.cc:16:2: warning: ‘A::a2’ should be initialized in the member
initialization list [-Weffc++]
63374.cc:16:2: warning: ‘A::a4’ should be initialized in the member
initialization list [-Weffc++]
63374.cc:16:38: error: no matching function for call to ‘B::B()’
A(int x) : b1(x), b2(x), b3(x), b4(x) {}
^
63374.cc:3:2: note: candidate: ‘B::B(int)’
B(int x) : z(x) {}
^
63374.cc:3:2: note: candidate expects 1 argument, 0 provided
63374.cc:1:7: note: candidate: ‘constexpr B::B(const B&)’
class B {
^
63374.cc:1:7: note: candidate expects 1 argument, 0 provided
63374.cc:1:7: note: candidate: ‘constexpr B::B(B&&)’
63374.cc:1:7: note: candidate expects 1 argument, 0 provided
$