From: Christoph Mallon Date: Tue, 18 Nov 2008 19:29:37 +0000 (+0000) Subject: Fix last commit. X-Git-Url: http://nsz.repo.hu/git/?a=commitdiff_plain;h=1e3bb5f311548c4262e5ffba9d8b1a0d19663f27;p=cparser Fix last commit. [r23779] --- diff --git a/parser.c b/parser.c index a07ee45..39e5dce 100644 --- a/parser.c +++ b/parser.c @@ -9790,7 +9790,7 @@ static void check_conditon_type(expression_t const *const expr, { type_t *const type = skip_typeref(expr->base.type); /* §6.8.5:2 */ - if (is_type_scalar(type) && is_type_valid(type)) { + if (!is_type_scalar(type) && is_type_valid(type)) { errorf(&expr->base.source_position, "condition of %s statement must have scalar type", stmt_name); }