aboutsummaryrefslogtreecommitdiff
path: root/gdb/c-exp.y
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/c-exp.y')
-rw-r--r--gdb/c-exp.y6
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/c-exp.y b/gdb/c-exp.y
index 5274118..8273f6a 100644
--- a/gdb/c-exp.y
+++ b/gdb/c-exp.y
@@ -721,8 +721,10 @@ ptype : typebase
case tp_array:
array_size = pop_type_int ();
if (array_size != -1)
- follow_type = create_array_type (follow_type,
- array_size);
+ follow_type =
+ create_array_type ((struct type *) NULL,
+ follow_type, builtin_type_int,
+ 0, array_size - 1);
else
follow_type = lookup_pointer_type (follow_type);
break;