https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94006
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2020-03-03
Ever confirmed|0 |1
Severity|normal |enhancement
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Confirmed.
Reduced testcase:
struct f
{
int t;
};
static const struct f g0 = {0};
static const struct f g1 = {-1};
struct f f1(int a, int b)
{
return a == b ? g0 : g1;
}
---- CUT -----
NOTE the C front-end has it done correctly.