https://gcc.gnu.org/bugzilla/show_bug.cgi?id=45784
--- Comment #8 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Author: jakub Date: Fri Sep 15 21:33:08 2017 New Revision: 252855 URL: https://gcc.gnu.org/viewcvs?rev=252855&root=gcc&view=rev Log: Backported from mainline 2017-07-27 Jakub Jelinek <ja...@redhat.com> PR c/45784 * c-omp.c (c_finish_omp_for): If the condition is wrapped in rhs of COMPOUND_EXPR(s), skip them and readd their lhs into new COMPOUND_EXPRs around the rhs of the comparison. * testsuite/libgomp.c/pr45784.c: New test. * testsuite/libgomp.c++/pr45784.C: New test. Added: branches/gcc-6-branch/libgomp/testsuite/libgomp.c++/pr45784.C branches/gcc-6-branch/libgomp/testsuite/libgomp.c/pr45784.c Modified: branches/gcc-6-branch/gcc/c-family/ChangeLog branches/gcc-6-branch/gcc/c-family/c-omp.c branches/gcc-6-branch/libgomp/ChangeLog