Class: SyntaxTree::RBrace

Inherits:
Node
  • Object
show all
Defined in:
lib/syntax_tree/node.rb

Overview

RBrace represents the use of a right brace, i.e., +++.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Node

#child_nodes, #deconstruct, #deconstruct_keys, #format, #pretty_print, #to_json

Constructor Details

#initialize(value:, location:) ⇒ RBrace

Returns a new instance of RBrace.



8485
8486
8487
8488
# File 'lib/syntax_tree/node.rb', line 8485

def initialize(value:, location:)
  @value = value
  @location = location
end

Instance Attribute Details

#locationObject (readonly)

Location

the location of this node



8483
8484
8485
# File 'lib/syntax_tree/node.rb', line 8483

def location
  @location
end

#valueObject (readonly)

String

the right brace



8480
8481
8482
# File 'lib/syntax_tree/node.rb', line 8480

def value
  @value
end