static struct astr {
int a;
};
static const struct astr newastr = {
.a = 9,
};
I get: warning: useless storage class specifier in empty declaration
If I change it to
static struct astr {
int a;
} something;
then the warning will be fixed.
The following also does not give that warning
struct astr {
int a;
};
static const struct astr newastr = {
.a = 9,
};
Can someone explain what is going on here?