aboutsummaryrefslogtreecommitdiff
path: root/gdb/rust-exp.y
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/rust-exp.y')
-rw-r--r--gdb/rust-exp.y10
1 files changed, 7 insertions, 3 deletions
diff --git a/gdb/rust-exp.y b/gdb/rust-exp.y
index 456ffe5..6dc4704 100644
--- a/gdb/rust-exp.y
+++ b/gdb/rust-exp.y
@@ -428,10 +428,14 @@ struct_expr_tail:
}
;
-/* S{} is documented as valid but seems to be an unstable feature, so
- it is left out here. */
struct_expr_list:
- struct_expr_tail
+ /* %empty */
+ {
+ VEC (set_field) **result
+ = OBSTACK_ZALLOC (&work_obstack, VEC (set_field) *);
+ $$ = result;
+ }
+| struct_expr_tail
{
VEC (set_field) **result
= OBSTACK_ZALLOC (&work_obstack, VEC (set_field) *);