@@ -1314,7 +1314,7 @@ VALUE parse_method_type(parserstate *state) {
13141314/*
13151315 global_decl ::= {tGIDENT} `:` <type>
13161316*/
1317- static VALUE parse_global_decl (parserstate * state ) {
1317+ static VALUE parse_global_decl (parserstate * state , VALUE annotations ) {
13181318 range decl_range ;
13191319 decl_range .start = state -> current_token .range .start ;
13201320
@@ -1334,7 +1334,7 @@ static VALUE parse_global_decl(parserstate *state) {
13341334 rbs_loc_add_required_child (loc , INTERN ("name" ), name_range );
13351335 rbs_loc_add_required_child (loc , INTERN ("colon" ), colon_range );
13361336
1337- return rbs_ast_decl_global (typename , type , location , comment );
1337+ return rbs_ast_decl_global (typename , type , location , comment , annotations );
13381338}
13391339
13401340/*
@@ -2606,7 +2606,7 @@ static VALUE parse_nested_decl(parserstate *state, const char *nested_in, positi
26062606 break ;
26072607 }
26082608 case tGIDENT : {
2609- decl = parse_global_decl (state );
2609+ decl = parse_global_decl (state , annotations );
26102610 break ;
26112611 }
26122612 case kTYPE : {
@@ -2651,7 +2651,7 @@ static VALUE parse_decl(parserstate *state) {
26512651 return parse_const_decl (state );
26522652 }
26532653 case tGIDENT : {
2654- return parse_global_decl (state );
2654+ return parse_global_decl (state , annotations );
26552655 }
26562656 case kTYPE : {
26572657 return parse_type_decl (state , annot_pos , annotations );
0 commit comments