lib/Get_Set.rb in Get_Set-1.0.0 vs lib/Get_Set.rb in Get_Set-1.1.0
- old
+ new
@@ -18,9 +18,10 @@
def attr_get_set *names
Array!(names).symbols!
names.each { |n|
class_eval %~
def #{n} *args
+ instance_variable_set( :@#{n}, nil ) unless instance_variable_defined?(:@#{n})
Get_Set! :@#{n}, *args
end
~, __FILE__, __LINE__
}
end