lib/dentaku/ast/function.rb in dentaku-3.4.2 vs lib/dentaku/ast/function.rb in dentaku-3.5.0

- old
+ new

@@ -2,27 +2,25 @@ require_relative 'function_registry' module Dentaku module AST class Function < Node + attr_reader :args + # @return [Integer] with the number of significant decimal digits to use. DIG = Float::DIG + 1 def initialize(*args) @args = args end + def accept(visitor) + visitor.visit_function(self) + end + def dependencies(context = {}) - deferred = deferred_args @args.each_with_index - .reject { |_, i| deferred.include? i } .flat_map { |a, _| a.dependencies(context) } - end - - # override if your function implementation needs to defer evaluation of - # any arguments - def deferred_args - [] end def self.get(name) registry.get(name) end