mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/set.rb: Enable frozen_string_literal.
* lib/set.rb: Move << out of the begin block that ensures pop. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52593 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
dcfcef1cfd
commit
5cf4310616
2 changed files with 9 additions and 1 deletions
|
@ -1,3 +1,9 @@
|
|||
Mon Nov 16 16:39:38 2015 Akinori MUSHA <knu@iDaemons.org>
|
||||
|
||||
* lib/set.rb: Enable frozen_string_literal.
|
||||
|
||||
* lib/set.rb: Move << out of the begin block that ensures pop.
|
||||
|
||||
Mon Nov 16 16:28:30 2015 Akinori MUSHA <knu@iDaemons.org>
|
||||
|
||||
* lib/set.rb (Hash#flatten!, #add?, #delete?, #collect!, #reject!,
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
#--
|
||||
# frozen_string_literal: true
|
||||
#
|
||||
# set.rb - defines the Set class
|
||||
#++
|
||||
# Copyright (c) 2002-2013 Akinori MUSHA <knu@iDaemons.org>
|
||||
|
@ -534,8 +536,8 @@ class Set
|
|||
return sprintf('#<%s: {...}>', self.class.name)
|
||||
end
|
||||
|
||||
ids << object_id
|
||||
begin
|
||||
ids << object_id
|
||||
return sprintf('#<%s: {%s}>', self.class, to_a.inspect[1..-2])
|
||||
ensure
|
||||
ids.pop
|
||||
|
|
Loading…
Add table
Reference in a new issue