+2006-04-23 Eric Botcazou <ebotcazou@adacore.com>
+
+ * fold-const.c (range_predecessor): Use operand_equal_p
+ as the predicate for equality.
+ (range_successor): Likewise.
+
2006-04-22 Kazu Hirata <kazu@codesourcery.com>
Revert:
{
tree type = TREE_TYPE (val);
- if (INTEGRAL_TYPE_P (type) && val == TYPE_MIN_VALUE (type))
+ if (INTEGRAL_TYPE_P (type)
+ && operand_equal_p (val, TYPE_MIN_VALUE (type), 0))
return 0;
else
return range_binop (MINUS_EXPR, NULL_TREE, val, 0, integer_one_node, 0);
{
tree type = TREE_TYPE (val);
- if (INTEGRAL_TYPE_P (type) && val == TYPE_MAX_VALUE (type))
+ if (INTEGRAL_TYPE_P (type)
+ && operand_equal_p (val, TYPE_MAX_VALUE (type), 0))
return 0;
else
return range_binop (PLUS_EXPR, NULL_TREE, val, 0, integer_one_node, 0);