[Bug c/59871] [4.7/4.8/4.9 Regression] No unused value warning for comma expression

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Sat Jan 18 10:08:00 GMT 2014


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59871

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
I'd say easiest would be at the spot where we warn currently about the
left-hand ... check if the left hand operand is a COMPOUND_EXPR, in that case
find the rightmost operand of all the nested COMPOUND_EXPRs and complain about
right-hand operand instead of left-hand.  Perhaps needs some tweaks to get the
locus right.



More information about the Gcc-bugs mailing list