[Bug other/106370] enhancement: last statement of loop is continue is redundant ?

marxin at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Jul 22 07:31:02 GMT 2022


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

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|ASSIGNED                    |RESOLVED

--- Comment #4 from Martin Liška <marxin at gcc dot gnu.org> ---
Fixes 2 locations, for the rest it seems fine to me the way we write empty body
loop:

  for (insn = get_insns (); insn; insn = conditionalize_block (insn))
    continue;

The warning should be omitted when the only statement in a loop in 'continue'.


More information about the Gcc-bugs mailing list