2013-11-26 Paolo Carlini <paolo.carlini@oracle.com>
* cvt.c (cp_convert_and_check): Avoid calling cp_convert
unnecessarily.
From-SVN: r205387
+2013-11-26 Paolo Carlini <paolo.carlini@oracle.com>
+
+ * cvt.c (cp_convert_and_check): Avoid calling cp_convert
+ unnecessarily.
+
2013-11-25 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/54485
{
tree folded = maybe_constant_value (expr);
tree stripped = folded;
- tree folded_result = cp_convert (type, folded, complain);
+ tree folded_result
+ = folded != expr ? cp_convert (type, folded, complain) : result;
/* maybe_constant_value wraps an INTEGER_CST with TREE_OVERFLOW in a
NOP_EXPR so that it isn't TREE_CONSTANT anymore. */