https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97544
Marek Polacek changed:
What|Removed |Added
Resolution|--- |DUPLICATE
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97544
--- Comment #4 from Benedek Thaler ---
FTR, Using (N != 0 && i < N) does not silence the warning.
https://gcc.godbolt.org/z/WqaT3G
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97544
Marek Polacek changed:
What|Removed |Added
CC||mpolacek at gcc dot gnu.org
--- Comment
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97544
--- Comment #2 from Jonathan Wakely ---
It's right, but it's not helpful. There are other instantiations of the
template where the condition isn't always true, and users shouldn't have to
write the condition as (N != 0 && i < N) just to silence
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97544
Jakub Jelinek changed:
What|Removed |Added
CC||jakub at gcc dot gnu.org
--- Comment #1