Class: Grammar::Ruby::Code::Command

Inherits:
Grammar::Ruby::Code show all
Defined in:
lib/grammar/ruby/code.rb

Direct Known Subclasses

Dedented

Constant Summary

Constants inherited from Grammar::Ruby::Code

False, FalseTerminator, Implicit, Nil, Self, True

Instance Method Summary collapse

Methods inherited from Grammar::Ruby::Code

[], #_and, #_assign, #_classname, #_code_self, #_def, #_dot, #_else, #_ensure, #_equal, #_immediate, #_inspect, #_mid, #_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

#_alwaysObject



235
236
237
# File 'lib/grammar/ruby/code.rb', line 235

def _always
    false
end

#_codesObject



229
230
231
# File 'lib/grammar/ruby/code.rb', line 229

def _codes
    []
end

#_dataObject



232
233
234
# File 'lib/grammar/ruby/code.rb', line 232

def _data
    @code
end

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



226
227
228
# File 'lib/grammar/ruby/code.rb', line 226

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

#_locals(n = 0) ⇒ Object



241
242
243
# File 'lib/grammar/ruby/code.rb', line 241

def _locals(n=0)
    n
end

#_neverObject



238
239
240
# File 'lib/grammar/ruby/code.rb', line 238

def _never
    false
end