Class: SyntaxTree::Parser::Semicolon
- Inherits:
-
Object
- Object
- SyntaxTree::Parser::Semicolon
- Defined in:
- lib/syntax_tree/parser.rb
Overview
Semicolons are tokens that get added to the token list but never get attached to the AST. Because of this they only need to track their associated location so they can be used for computing bounds.
Instance Attribute Summary collapse
-
#location ⇒ Object
readonly
Returns the value of attribute location.
Instance Method Summary collapse
-
#initialize(location) ⇒ Semicolon
constructor
A new instance of Semicolon.
Constructor Details
#initialize(location) ⇒ Semicolon
Returns a new instance of Semicolon.
3367 3368 3369 |
# File 'lib/syntax_tree/parser.rb', line 3367 def initialize(location) @location = location end |
Instance Attribute Details
#location ⇒ Object (readonly)
Returns the value of attribute location.
3365 3366 3367 |
# File 'lib/syntax_tree/parser.rb', line 3365 def location @location end |