Commit b7647895 by Jim Wilson

(fold...

(fold, COMPOUND_EXPR case): When pedantic, don't
simplify a COMPOUND_EXPR, so that it won't be mistaken for an
lvalue or an integer constant expression.

From-SVN: r4103
parent 29df70e6
......@@ -4413,7 +4413,9 @@ fold (expr)
return t;
case COMPOUND_EXPR:
if (TREE_SIDE_EFFECTS (arg0))
/* When pedantic, a compound expression can be neither an lvalue
nor an integer constant expression. */
if (TREE_SIDE_EFFECTS (arg0) || pedantic)
return t;
/* Don't let (0, 0) be null pointer constant. */
if (integer_zerop (arg1))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment