Class: Electr::FuncNameAST

Inherits:
AST
  • Object
show all
Defined in:
lib/electr/ast/func_name_ast.rb

Overview

A node in the AST to represent the name of a function, ie sqrt, sin or cos.

Instance Attribute Summary

Attributes inherited from AST

#children, #name, #value

Instance Method Summary collapse

Methods inherited from AST

#add_child, #display, #leaf?, #size, #to_pn

Constructor Details

#initialize(value) ⇒ FuncNameAST

Returns a new instance of FuncNameAST.



7
8
9
10
# File 'lib/electr/ast/func_name_ast.rb', line 7

def initialize(value)
  super("funcname")
  @value = value
end