Consider this code:
struct S
{
int x;
double y = 1.1;
};
int main()
{
S s = {0};
}
According to the C++14 standard, § 8.5.1/7<
You are correct, this is valid C++14; however, in C++11 a class with in class member initializers was not an aggregate and so this is not valid in C++11.
The issue as I noted in my answer to the above question and I realized later after I made my initial comment is that gcc did not support this change until 5.0 (see it live):
G++ now supports C++14 aggregates with non-static data member initializers.
struct A { int i, j = i; }; A a = { 42 }; // a.j is also 42