Class: Red::ControlNode::Keyword
- Inherits:
-
Red::ControlNode
- Object
- String
- Red::ControlNode
- Red::ControlNode::Keyword
- Defined in:
- lib/red/nodes/control_nodes.rb
Overview
:nodoc:
Defined Under Namespace
Instance Method Summary collapse
-
#initialize(*arguments_array_sexp) ⇒ Keyword
constructor
- :break, (expression)
-
[:next, (expression)].
Methods inherited from String
#%, #*, #+, #<<, #<=>, #==, #=~, #[], #[]=, #capitalize, #capitalize!, #casecmp, #center, #chomp, #chomp!, #chop, #chop!, #concat, #count, #crypt, #delete, #delete!, #downcase, #downcase!, #each, #each_byte, #each_line, #empty?, #eql?, #gsub, #gsub!, #hash, #hex, #include?, #index, #insert, #inspect, #intern, #length, #ljust, #lstrip, #lstrip!, #match, #next, #next!, #oct, #replace, #reverse, #reverse!, #rindex, #rjust, #rstrip, #rstrip!, #scan, #size, #slice, #slice!, #split, #squeeze, #strip, #strip!, #strip_scripts, #sub, #sub!, #succ, #succ!, #sum, #swapcase, #swapcase!, #to_f, #to_i, #to_s, #to_str, #to_sym, #tr, #tr!, #tr_s, #tr_s!, #upcase, #upcase!, #upto
Constructor Details
#initialize(*arguments_array_sexp) ⇒ Keyword
- :break, (expression)
- :next, (expression)
75 76 77 78 79 80 |
# File 'lib/red/nodes/control_nodes.rb', line 75 def initialize(*arguments_array_sexp) = arguments_array_sexp.pop arguments = arguments_array_sexp.map {|arg| arg.red!(:as_argument => true) }.join(",") keyword = self.class.to_s.split('::').last.downcase self << "Red.LoopError._%s(%s)" % [keyword, arguments] end |