Sha256: 882db1a75c60431a825687901896b3966418c77b6e2a85ae36302d390d021bb1

Contents?: true

Size: 218 Bytes

Versions: 11

Compression:

Stored size: 218 Bytes

Contents

# import all functions from Ruby's Math module
require_relative "../function"

Math.methods(false).each do |method|
  Dentaku::AST::Function.register(method, :numeric, ->(*args) {
    Math.send(method, *args)
  })
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
dentaku-2.0.11 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.10 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.9 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.8 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.7 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.6 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.5 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.4 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.3 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.2 lib/dentaku/ast/functions/ruby_math.rb
dentaku-2.0.1 lib/dentaku/ast/functions/ruby_math.rb