Avoid super in define_method for Rubinius

This commit is contained in:
Yehuda Katz
2009-10-09 00:54:12 -10:00
parent ee37ff46e9
commit 2954cf1369

View File

@@ -10,7 +10,12 @@ module Mime
%w(<< concat shift unshift push pop []= clear compact! collect!
delete delete_at delete_if flatten! map! insert reject! reverse!
replace slice! sort! uniq!).each do |method|
define_method(method) {|*args| @symbols = nil; super(*args) }
module_eval <<-CODE
def #{method}(*args)
@symbols = nil
super
end
CODE
end
end