diff options
author | Jeremy Evans <code@jeremyevans.net> | 2019-10-27 16:03:07 -0700 |
---|---|---|
committer | Jeremy Evans <code@jeremyevans.net> | 2020-06-11 14:02:00 -0700 |
commit | a6cf2f3d22a78aeae9d7f36cc78a195deb686705 (patch) | |
tree | 30a4c537185f3d6fd0fb435f6d981569d30b5e84 /lib | |
parent | e100fcbdd1e81c23e3b4c87964aff210232903a8 (diff) | |
download | ruby-a6cf2f3d22a78aeae9d7f36cc78a195deb686705.tar.gz |
Make mutating the result of SortedSet#to_a not affect the set
Fixes [Bug #15834]
Diffstat (limited to 'lib')
-rw-r--r-- | lib/set.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/set.rb b/lib/set.rb index b8ab6ab172..d405d81178 100644 --- a/lib/set.rb +++ b/lib/set.rb @@ -778,7 +778,7 @@ class SortedSet < Set def to_a (@keys = @hash.keys).sort! unless @keys - @keys + @keys.dup end def freeze |