diff options
| -rw-r--r-- | evaluate.c | 2 | ||||
| -rw-r--r-- | validation/linear/bool-cast-lp32.c | 1 |
2 files changed, 2 insertions, 1 deletions
@@ -2883,6 +2883,8 @@ static struct symbol *cast_to_bool(struct expression *expr) return NULL; zero = alloc_const_expression(expr->pos, 0); + if (oclass & TYPE_PTR) + zero->ctype = otype; expr->op = SPECIAL_NOTEQUAL; ctype = usual_conversions(expr->op, old, zero, oclass, TYPE_NUM, otype, zero->ctype); diff --git a/validation/linear/bool-cast-lp32.c b/validation/linear/bool-cast-lp32.c index 44a650f4..7aab31dd 100644 --- a/validation/linear/bool-cast-lp32.c +++ b/validation/linear/bool-cast-lp32.c @@ -12,7 +12,6 @@ static _Bool ffun_e(void) { return (_Bool)ffun; } /* * check-name: bool-cast-pointer * check-command: test-linearize -m32 -fdump-ir $file - * check-known-to-fail * * check-output-ignore * check-output-excludes: ptrtu\\. |
