mirror of
https://github.com/ruby/ruby.git
synced 2025-09-15 16:44:01 +02:00
Change numeric node value functions argument to NODE *
Change the argument to align with other node value functions like `rb_node_line_lineno_val`.
This commit is contained in:
parent
d9bad91c34
commit
7ffff3e043
6 changed files with 59 additions and 55 deletions
|
@ -725,28 +725,28 @@ dump_node(VALUE buf, VALUE indent, int comment, const NODE * node)
|
|||
ANN("integer literal");
|
||||
ANN("format: [val]");
|
||||
ANN("example: 1");
|
||||
F_VALUE(val, rb_node_integer_literal_val(RNODE_INTEGER(node)), "val");
|
||||
F_VALUE(val, rb_node_integer_literal_val(node), "val");
|
||||
return;
|
||||
|
||||
case NODE_FLOAT:
|
||||
ANN("float literal");
|
||||
ANN("format: [val]");
|
||||
ANN("example: 1.2");
|
||||
F_VALUE(val, rb_node_float_literal_val(RNODE_FLOAT(node)), "val");
|
||||
F_VALUE(val, rb_node_float_literal_val(node), "val");
|
||||
return;
|
||||
|
||||
case NODE_RATIONAL:
|
||||
ANN("rational number literal");
|
||||
ANN("format: [val]");
|
||||
ANN("example: 1r");
|
||||
F_VALUE(val, rb_node_rational_literal_val(RNODE_RATIONAL(node)), "val");
|
||||
F_VALUE(val, rb_node_rational_literal_val(node), "val");
|
||||
return;
|
||||
|
||||
case NODE_IMAGINARY:
|
||||
ANN("complex number literal");
|
||||
ANN("format: [val]");
|
||||
ANN("example: 1i");
|
||||
F_VALUE(val, rb_node_imaginary_literal_val(RNODE_IMAGINARY(node)), "val");
|
||||
F_VALUE(val, rb_node_imaginary_literal_val(node), "val");
|
||||
return;
|
||||
|
||||
case NODE_ONCE:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue