Sha256: 33a0acd385f11d7959533ecb50481ba94fb8b7fa6b04976c9d368066a8e22217
Contents?: true
Size: 468 Bytes
Versions: 29
Compression:
Stored size: 468 Bytes
Contents
# frozen_string_literal: true class Code class Node class Not < Node def initialize(parsed) return if parsed.blank? @operator = parsed.delete(:operator).presence @right = Node::Statement.new(parsed.delete(:right).presence) end def evaluate(**args) if @right @right.evaluate(**args).call(operator: @operator, **args) else Object::Nothing.new end end end end end
Version data entries
29 entries across 29 versions & 1 rubygems