https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89134
--- Comment #10 from Jiangning Liu <jiangning.liu at amperecomputing dot com> --- (In reply to Martin Sebor from comment #9) > But since GCC emits infinite loops regardless of whether or not > they have any side-effects, whether inc() is pure or not may not matter. I think "for (; it != m.end (); ++it); /* get an empty loop */" is a finite loop.