summaryrefslogtreecommitdiff
path: root/node.c
diff options
context:
space:
mode:
Diffstat (limited to 'node.c')
-rw-r--r--node.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/node.c b/node.c
index 48fdf03c0a..885cef6c04 100644
--- a/node.c
+++ b/node.c
@@ -1058,11 +1058,12 @@ void
rb_node_init(NODE *n, enum node_type type, VALUE a0, VALUE a1, VALUE a2)
{
n->flags = T_NODE;
- n->nd_location = 0;
+ nd_set_type(n, type);
n->u1.value = a0;
n->u2.value = a1;
n->u3.value = a2;
- nd_set_type(n, type);
+ n->nd_first_loc.lineno = 0;
+ n->nd_first_loc.column = 0;
}
typedef struct node_buffer_elem_struct {