From db2d28b08e73a6f1698b578e53daaf230c3ce2bf Mon Sep 17 00:00:00 2001 From: nobu Date: Thu, 7 Dec 2017 04:12:42 +0000 Subject: parse.y: fix for old compilers * parse.y (arg_value): initialization of aggregation type with non-constant values is not allowed in C89. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61068 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- parse.y | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/parse.y b/parse.y index 109c227e09..4279ea6e3a 100644 --- a/parse.y +++ b/parse.y @@ -4998,7 +4998,9 @@ assoc : arg_value tASSOC arg_value | tSTRING_BEG string_contents tLABEL_END arg_value { /*%%%*/ - YYLTYPE location = {@1.first_loc, @3.last_loc}; + YYLTYPE location; + location.first_loc = @1.first_loc; + location.last_loc = @3.last_loc; $$ = list_append(new_list(dsym_node($2, &location), &location), $4, &@$); /*% $$ = dispatch2(assoc_new, dispatch1(dyna_symbol, $2), $4); -- cgit v1.2.3