Commit 91378b76 by Jason Merrill

(warn_if_unused_value): Extend special case for casted

        MODIFY_EXPRs to apply to INIT_EXPRs as well.

From-SVN: r8008
parent ad83e87b
......@@ -1730,7 +1730,7 @@ warn_if_unused_value (exp)
while (TREE_CODE (tem) == CONVERT_EXPR || TREE_CODE (tem) == NOP_EXPR)
tem = TREE_OPERAND (tem, 0);
if (TREE_CODE (tem) == MODIFY_EXPR)
if (TREE_CODE (tem) == MODIFY_EXPR || TREE_CODE (tem) == INIT_EXPR)
return 0;
}
/* ... fall through ... */
......
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