@@ -1156,7 +1156,7 @@ static rb_node_true_t *rb_node_true_new(struct parser_params *p, const YYLTYPE *
11561156static rb_node_false_t *rb_node_false_new(struct parser_params *p, const YYLTYPE *loc);
11571157static rb_node_errinfo_t *rb_node_errinfo_new(struct parser_params *p, const YYLTYPE *loc);
11581158static rb_node_defined_t *rb_node_defined_new(struct parser_params *p, NODE *nd_head, const YYLTYPE *loc);
1159- static rb_node_postexe_t *rb_node_postexe_new(struct parser_params *p, NODE *nd_body, const YYLTYPE *loc);
1159+ static rb_node_postexe_t *rb_node_postexe_new(struct parser_params *p, NODE *nd_body, const YYLTYPE *loc, const YYLTYPE *keyword_loc, const YYLTYPE *opening_loc, const YYLTYPE *closing_loc );
11601160static rb_node_sym_t *rb_node_sym_new(struct parser_params *p, VALUE str, const YYLTYPE *loc);
11611161static rb_node_dsym_t *rb_node_dsym_new(struct parser_params *p, rb_parser_string_t *string, long nd_alen, NODE *nd_next, const YYLTYPE *loc);
11621162static rb_node_attrasgn_t *rb_node_attrasgn_new(struct parser_params *p, NODE *nd_recv, ID nd_mid, NODE *nd_args, const YYLTYPE *loc);
@@ -1264,7 +1264,7 @@ static rb_node_error_t *rb_node_error_new(struct parser_params *p, const YYLTYPE
12641264#define NEW_FALSE(loc) (NODE *)rb_node_false_new(p,loc)
12651265#define NEW_ERRINFO(loc) (NODE *)rb_node_errinfo_new(p,loc)
12661266#define NEW_DEFINED(e,loc) (NODE *)rb_node_defined_new(p,e,loc)
1267- #define NEW_POSTEXE(b,loc) (NODE *)rb_node_postexe_new(p,b,loc)
1267+ #define NEW_POSTEXE(b,loc,k_loc,o_loc,c_loc ) (NODE *)rb_node_postexe_new(p,b,loc,k_loc,o_loc,c_loc )
12681268#define NEW_SYM(str,loc) (NODE *)rb_node_sym_new(p,str,loc)
12691269#define NEW_DSYM(s,l,n,loc) (NODE *)rb_node_dsym_new(p,s,l,n,loc)
12701270#define NEW_ATTRASGN(r,m,a,loc) (NODE *)rb_node_attrasgn_new(p,r,m,a,loc)
@@ -3314,7 +3314,7 @@ stmt : keyword_alias fitem {SET_LEX_STATE(EXPR_FNAME|EXPR_FITEM);} fitem
33143314 p->ctxt = $k_END;
33153315 {
33163316 NODE *scope = NEW_SCOPE2(0 /* tbl */, 0 /* args */, $compstmt /* body */, &@$);
3317- $$ = NEW_POSTEXE(scope, &@$);
3317+ $$ = NEW_POSTEXE(scope, &@$, &@1, &@3, &@5 );
33183318 }
33193319 /*% ripper: END!($:compstmt) %*/
33203320 }
@@ -12272,10 +12272,13 @@ rb_node_defined_new(struct parser_params *p, NODE *nd_head, const YYLTYPE *loc)
1227212272}
1227312273
1227412274static rb_node_postexe_t *
12275- rb_node_postexe_new(struct parser_params *p, NODE *nd_body, const YYLTYPE *loc)
12275+ rb_node_postexe_new(struct parser_params *p, NODE *nd_body, const YYLTYPE *loc, const YYLTYPE *keyword_loc, const YYLTYPE *opening_loc, const YYLTYPE *closing_loc )
1227612276{
1227712277 rb_node_postexe_t *n = NODE_NEWNODE(NODE_POSTEXE, rb_node_postexe_t, loc);
1227812278 n->nd_body = nd_body;
12279+ n->keyword_loc = *keyword_loc;
12280+ n->opening_loc = *opening_loc;
12281+ n->closing_loc = *closing_loc;
1227912282
1228012283 return n;
1228112284}
0 commit comments