Project

General

Profile

« Previous | Next » 

Revision f23485a8

Added by yui-knk (Kaneko Yuichiro) 11 months ago

[Feature #20624] Enhance RubyVM::AbstractSyntaxTree::Node#locations

This commit introduce RubyVM::AbstractSyntaxTree::Node#locations method
and RubyVM::AbstractSyntaxTree::Location class.

Ruby AST node will hold multiple locations information.
RubyVM::AbstractSyntaxTree::Node#locations provides a way to access
these locations information.

RubyVM::AbstractSyntaxTree::Location is a class which holds these location information:

  • #first_lineno
  • #first_column
  • #last_lineno
  • #last_column