Class: SyntaxTree::RBracket

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

Overview

RBracket represents the use of a right bracket, i.e., ].

Instance Attribute Summary collapse

Attributes inherited from Node

#location

Instance Method Summary collapse

Methods inherited from Node

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

Constructor Details

#initialize(value:, location:) ⇒ RBracket

Returns a new instance of RBracket.



8193
8194
8195
8196
# File 'lib/syntax_tree/node.rb', line 8193

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

Instance Attribute Details

#valueObject (readonly)

String

the right bracket



8191
8192
8193
# File 'lib/syntax_tree/node.rb', line 8191

def value
  @value
end