Class: NodeType
Overview
NodeType is an abstraction for the C type of a node. It is a Struct which has two members, name and value.
Instance Method Summary collapse
-
#to_i ⇒ Numeric
Returns an integer representing integer type of a node.
-
#name ⇒ String
Returns the name of the node.
Instance Method Details
#to_i ⇒ Numeric
Returns an integer representing integer type of a node. This is the value you would see for the type of the node if you were examining it in gdb.
486 487 488 489 |
# File 'ext/nodewrap.c', line 486 static VALUE node_type_to_i(VALUE node_type) { return rb_struct_getmember(node_type, rb_intern("value")); } |
#name ⇒ String
Returns the name of the node.
473 474 475 476 |
# File 'ext/nodewrap.c', line 473 static VALUE node_type_to_s(VALUE node_type) { return rb_struct_getmember(node_type, rb_intern("name")); } |