t2 = int2int(e2p, (int_size<long_size)? long_type : ulong_type);
else if (t2 == LONG && t1 == INT && u1 && !shifting) /* ??? */
t1 = int2int(e1p, (int_size<long_size)? long_type : ulong_type);
- if (int_size > long_size) /* sanity check */
- crash("size of int exceeds size of long");
/* If either operand has type long int, the other operand is con-
verted to long int.
if (t2 == LONG && t1 != LONG && !shifting) /* ??? */
t1 = int2int(e1p, long_type);
+ u1 = (*e1p)->ex_type->tp_unsigned;
+ u2 = (*e2p)->ex_type->tp_unsigned;
+
/* If either operand has type unsigned int, the other operand
is converted to unsigned int.
Otherwise, both operands have type int.
else if (is_fp_cst(expr) && is_fp_cst(ex))
fltcstbin(expp, oper, expr);
else {
- *expp = (commutative && (expr->ex_depth >= ex->ex_depth
- || is_cp_cst(ex)))
+ *expp = (commutative &&
+ ! (ex->ex_flags & EX_VOLATILE) &&
+ ( expr->ex_depth > ex->ex_depth ||
+ (expr->ex_flags & EX_SIDEEFFECTS) ||
+ is_cp_cst(ex)))
? new_oper(ex->ex_type, expr, oper, ex)
: new_oper(ex->ex_type, ex, oper, expr);
}