Print this page
new smatch
*** 76,91 ****
{
struct expression *tmp = NULL;
struct expression *zero;
// if left is zero or right is zero
! if (is_zero(expr->left)) {
zero = strip_expr(expr->left);
if (zero->type != EXPR_VALUE)
__split_expr(expr->left);
tmp = expr->right;
! } else if (is_zero(expr->right)) {
zero = strip_expr(expr->left);
if (zero->type != EXPR_VALUE)
__split_expr(expr->right);
tmp = expr->left;
} else {
--- 76,91 ----
{
struct expression *tmp = NULL;
struct expression *zero;
// if left is zero or right is zero
! if (expr_is_zero(expr->left)) {
zero = strip_expr(expr->left);
if (zero->type != EXPR_VALUE)
__split_expr(expr->left);
tmp = expr->right;
! } else if (expr_is_zero(expr->right)) {
zero = strip_expr(expr->left);
if (zero->type != EXPR_VALUE)
__split_expr(expr->right);
tmp = expr->left;
} else {