Class: RedParse::DeleteMonkey
- Inherits:
-
StackMonkey
- Object
- StackMonkey
- RedParse::DeleteMonkey
- Defined in:
- lib/redparse.rb,
lib/miniredparse.rb
Instance Attribute Summary
Attributes inherited from StackMonkey
#and_expect_node, #exemplars, #first_changed_index, #monkey_code, #name
Instance Method Summary collapse
-
#initialize(index, name) ⇒ DeleteMonkey
constructor
A new instance of DeleteMonkey.
Methods inherited from StackMonkey
Constructor Details
#initialize(index, name) ⇒ DeleteMonkey
Returns a new instance of DeleteMonkey.
122 123 124 125 126 |
# File 'lib/redparse.rb', line 122 def initialize(index,name) index=-index if index>0 @index=index super(name,index,nil){|stack| stack.delete_at( index )} end |