https://gcc.gnu.org/bugzilla/show_bug.cgi?id=123850
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- I am almost positive this is a won't fix for GCC 15 as the warning goes away if you implement this into another function besides main (which is why r16-372-g064cac730f88dc fixes it for main).
