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

--- Comment #10 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to James Hilliard from comment #8) 
> Yeah, clang with -std=gnu17 -pedantic doesn't even complain at all from the
> looks of it. Does it make sense to allow disabling this specific warning in
> GCC?

No it does not make sense at all to disable this specific warning; maybe
request clang implement the warning too.

> What would be the correct way to fix these in bpf-next?

Move the struct definition outside of the function definition? You could ask
the bpf mailing list of what is the fix they would like to see for this
questionable code.

Reply via email to