class Highway::Compiler::Analyze::Tree::Segments::Variable

This class represents a variable value segment in the semantic tree. It consists of a variable name and its lookup scope.

Attributes

name[R]

The variable name.

@return [String]

scope[R]

The lookup scope of the variable.

@return [Symbol]

Public Class Methods

new(name, scope:) click to toggle source

Initialize an instance.

@param name [String] The variable name. @param scope [Symbol] The lookup scope of variable.

# File lib/highway/compiler/analyze/tree/segments/variable.rb, line 22
def initialize(name, scope:)
  @name = name
  @scope = scope
end