aboutsummaryrefslogtreecommitdiffstats
path: root/node.c
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2021-12-12 23:33:47 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2021-12-13 12:53:03 +0900
commit54f0e63a8c53753af7db8653972ac450415eae13 (patch)
treedac9a7e9874c5ce570db851a9052297b5978961c /node.c
parentd3c8f7b1cd2fdba95436889869e94f4c3cf419e8 (diff)
downloadruby-54f0e63a8c53753af7db8653972ac450415eae13.tar.gz
Remove `NODE_DASGN_CURR` [Feature #18406]
This `NODE` type was used in pre-YARV implementation, to improve the performance of assignment to dynamic local variable defined at the innermost scope. It has no longer any actual difference with `NODE_DASGN`, except for the node dump.
Diffstat (limited to 'node.c')
-rw-r--r--node.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/node.c b/node.c
index fe1a60c151..d8c1da95ef 100644
--- a/node.c
+++ b/node.c
@@ -407,16 +407,9 @@ dump_node(VALUE buf, VALUE indent, int comment, const NODE * node)
}
return;
case NODE_DASGN:
- ANN("dynamic variable assignment (out of current scope)");
+ ANN("dynamic variable assignment");
ANN("format: [nd_vid](dvar) = [nd_value]");
ANN("example: x = nil; 1.times { x = foo }");
- F_ID(nd_vid, "local variable");
- LAST_NODE;
- F_NODE(nd_value, "rvalue");
- return;
- case NODE_DASGN_CURR:
- ANN("dynamic variable assignment (in current scope)");
- ANN("format: [nd_vid](current dvar) = [nd_value]");
ANN("example: 1.times { x = foo }");
F_ID(nd_vid, "local variable");
if (NODE_REQUIRED_KEYWORD_P(node)) {