summaryrefslogtreecommitdiff
path: root/node.c
diff options
context:
space:
mode:
Diffstat (limited to 'node.c')
-rw-r--r--node.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/node.c b/node.c
index 558a4cef47..864e115472 100644
--- a/node.c
+++ b/node.c
@@ -1010,7 +1010,14 @@ dump_node(VALUE buf, VALUE indent, int comment, const NODE * node)
F_INT(nd_ainfo->post_args_num, "count of mandatory post-arguments");
F_NODE(nd_ainfo->post_init, "initialization of post-arguments");
F_ID(nd_ainfo->first_post_arg, "first post argument");
- F_ID(nd_ainfo->rest_arg, "rest argument");
+ F_CUSTOM1(nd_ainfo->rest_arg, "rest argument") {
+ if (node->nd_ainfo->rest_arg == NODE_SPECIAL_EXCESSED_COMMA) {
+ A("1 (excessed comma)");
+ }
+ else {
+ A_ID(node->nd_ainfo->rest_arg);
+ }
+ }
F_ID(nd_ainfo->block_arg, "block argument");
F_NODE(nd_ainfo->opt_args, "optional arguments");
F_NODE(nd_ainfo->kw_args, "keyword arguments");