Class: Grammar::Ruby::Code::Not
Constant Summary
False, FalseTerminator, Implicit, Nil, Self, True
Instance Method Summary
collapse
Methods inherited from Unary
#_codes, #_lines
[], #_and, #_assign, #_classname, #_code_self, #_codes, #_def, #_dot, #_else, #_ensure, #_equal, #_immediate, #_inspect, #_lines, #_locals, #_or, #_question, #_rand, #_rcond, #_rescue, #_ror, #_rstep, #_splat, #_to_block, #_unless, #_until, #_while, #method_missing
Constructor Details
#initialize(operand) ⇒ Not
Returns a new instance of Not.
391
392
393
|
# File 'lib/grammar/ruby/code.rb', line 391
def initialize(operand)
@operand = operand
end
|
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
in the class Grammar::Ruby::Code
Instance Method Details
#_always ⇒ Object
400
401
402
|
# File 'lib/grammar/ruby/code.rb', line 400
def _always
@operand._never
end
|
#_data ⇒ Object
394
395
396
|
# File 'lib/grammar/ruby/code.rb', line 394
def _data
nil
end
|
#_mid(before) ⇒ Object
409
410
411
|
# File 'lib/grammar/ruby/code.rb', line 409
def _mid(before)
@operand._mid(before)
end
|
#_never ⇒ Object
403
404
405
|
# File 'lib/grammar/ruby/code.rb', line 403
def _never
@operand._always
end
|
#_not ⇒ Object
406
407
408
|
# File 'lib/grammar/ruby/code.rb', line 406
def _not
@operand
end
|
#_operator ⇒ Object
397
398
399
|
# File 'lib/grammar/ruby/code.rb', line 397
def _operator
"!"
end
|
#_step(after) ⇒ Object
412
413
414
|
# File 'lib/grammar/ruby/code.rb', line 412
def _step(after)
@operand._step(after)
end
|