diff options
author | ydah <[email protected]> | 2024-09-10 16:41:27 +0900 |
---|---|---|
committer | Yuichiro Kaneko <[email protected]> | 2024-09-11 18:01:16 +0900 |
commit | d03e0d1c35638fcd3b474bf604c855f132356e6d (patch) | |
tree | fc528b850c077ada83b5da5b20198c3a8abcde46 /node_dump.c | |
parent | f7ffa76377ead1760dcb0a84db282facb461ecd7 (diff) |
Implement BREAK, NEXT and REDO NODE locations
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/11584
Diffstat (limited to 'node_dump.c')
-rw-r--r-- | node_dump.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/node_dump.c b/node_dump.c index 64b0cb8b7f..7c2faf3f42 100644 --- a/node_dump.c +++ b/node_dump.c @@ -352,15 +352,17 @@ dump_node(VALUE buf, VALUE indent, int comment, const NODE * node) ANN("break statement"); ANN("format: break [nd_stts]"); ANN("example: break 1"); - LAST_NODE; F_NODE(nd_stts, RNODE_BREAK, "value"); + LAST_NODE; + F_LOC(keyword_loc, RNODE_REDO); return; case NODE_NEXT: ANN("next statement"); ANN("format: next [nd_stts]"); ANN("example: next 1"); - LAST_NODE; F_NODE(nd_stts, RNODE_NEXT, "value"); + LAST_NODE; + F_LOC(keyword_loc, RNODE_REDO); return; case NODE_RETURN: ANN("return statement"); @@ -374,6 +376,7 @@ dump_node(VALUE buf, VALUE indent, int comment, const NODE * node) ANN("redo statement"); ANN("format: redo"); ANN("example: redo"); + F_LOC(keyword_loc, RNODE_REDO); return; case NODE_RETRY: |