summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorknu <knu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-06-01 09:01:16 +0000
committerknu <knu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-06-01 09:01:16 +0000
commit6bdfe415df2ef15487ba932762c028640b8ff71a (patch)
tree7b97e0a7804c57c23191d7bf3d708e2aee1df6ab /lib
parent4a223fb67f31a1a85a0b4fb019a1106532a541ce (diff)
* lib/set.rb (Set#freeze, taint, untaint): Save a "self" by
utilizing super returning self, and add tests while at it. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41022 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib')
-rw-r--r--lib/set.rb9
1 files changed, 3 insertions, 6 deletions
diff --git a/lib/set.rb b/lib/set.rb
index cc7542f223..a9aa7e7936 100644
--- a/lib/set.rb
+++ b/lib/set.rb
@@ -99,21 +99,18 @@ class Set
end
def freeze # :nodoc:
- super
@hash.freeze
- self
+ super
end
def taint # :nodoc:
- super
@hash.taint
- self
+ super
end
def untaint # :nodoc:
- super
@hash.untaint
- self
+ super
end
# Returns the number of elements.