skip_typeref().
authorChristoph Mallon <christoph.mallon@gmx.de>
Fri, 6 Feb 2009 12:24:54 +0000 (12:24 +0000)
committerChristoph Mallon <christoph.mallon@gmx.de>
Fri, 6 Feb 2009 12:24:54 +0000 (12:24 +0000)
[r25444]

parser.c

index 3b67e2e..4767ba6 100644 (file)
--- a/parser.c
+++ b/parser.c
@@ -4395,7 +4395,7 @@ static construct_type_t *parse_array_declarator(void)
                expression_t *const size = parse_assignment_expression();
 
                /* ยง6.7.5.2:1  Array size must have integer type */
-               if (!is_type_integer(size->base.type)) {
+               if (!is_type_integer(skip_typeref(size->base.type))) {
                        errorf(&size->base.source_position,
                               "array size '%E' must have integer type but has type '%T'",
                               size, size->base.type);