class So::Not
Attributes
x[R]
Public Class Methods
new(x)
click to toggle source
# File lib/spec_object.rb, line 254 def initialize(x) @x = x end
not_(x)
click to toggle source
# File lib/spec_object.rb, line 260 def self.not_(x) x = x.to_so_expr if x.kind_of?(Const) (!(x.value)).to_so_expr elsif x.kind_of?(Not) x.x else new(x) end end
Public Instance Methods
evaluate(calls)
click to toggle source
# File lib/spec_object.rb, line 280 def evaluate(calls) Not.not_(@x.evaluate(calls)) end
pp(n)
click to toggle source
# File lib/spec_object.rb, line 272 def pp(n) "#{' '*n}(not\n#{@x.pp(n+2)})" end
substitute(v, e)
click to toggle source
# File lib/spec_object.rb, line 276 def substitute(v, e) Not.not_(@x.substitute(v, e)) end