Class: Grammar::Ruby::Code::Immediate

Inherits:
Primary show all
Defined in:
lib/grammar/ruby/code.rb

Constant Summary

Constants inherited from Grammar::Ruby::Code

False, FalseTerminator, Implicit, Nil, Self, True

Instance Method Summary collapse

Methods inherited from Primary

#_always, #_codes, #_locals, #_mid, #_never, #_step

Methods inherited from Grammar::Ruby::Code

[], #_always, #_and, #_assign, #_classname, #_code_self, #_codes, #_def, #_dot, #_else, #_ensure, #_equal, #_inspect, #_locals, #_mid, #_never, #_not, #_or, #_question, #_rand, #_rcond, #_rescue, #_ror, #_rstep, #_splat, #_step, #_to_block, #_unless, #_until, #_while, #initialize, #method_missing

Constructor Details

This class inherits a constructor from Grammar::Ruby::Code

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Grammar::Ruby::Code

Instance Method Details

#_dataObject



249
250
251
# File 'lib/grammar/ruby/code.rb', line 249

def _data
    @code
end

#_immediateObject



246
247
248
# File 'lib/grammar/ruby/code.rb', line 246

def _immediate
    true
end

#_lines(text, indent = 0, op = nil, maxlen = 72) ⇒ Object



252
253
254
# File 'lib/grammar/ruby/code.rb', line 252

def _lines(text, indent=0, op=nil, maxlen=72)
    text.last.concat(@code.inspect)
end