summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-06-21 08:20:12 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-06-21 08:20:12 +0000
commit0cc816db25367d6bcf91ac0dfe66ed25a3d37725 (patch)
tree7d6cd1b77f0a2dcc9dfe87d8d12b9a844fceea43 /lib
parent97ea999e0487a49b21b31cc40fff3aa0251b6bd9 (diff)
downloadruby-0cc816db25367d6bcf91ac0dfe66ed25a3d37725.tar.gz
ruby-0cc816db25367d6bcf91ac0dfe66ed25a3d37725.tar.xz
ruby-0cc816db25367d6bcf91ac0dfe66ed25a3d37725.zip
* lib/pp.rb (PP::PPMethods::seplist): should have preserved
original reference to the array. [ruby-dev:28747] git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@10357 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib')
-rw-r--r--lib/pp.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/pp.rb b/lib/pp.rb
index 992369911..266949e22 100644
--- a/lib/pp.rb
+++ b/lib/pp.rb
@@ -143,7 +143,7 @@ class PP < PrettyPrint
# printed, a.k.a the object reference chain has a cycle.
def pp(obj)
id = obj.__id__
-
+
if check_inspect_key(id)
group {obj.pretty_print_cycle self}
return
@@ -220,13 +220,13 @@ class PP < PrettyPrint
def seplist(list, sep=nil, iter_method=:each) # :yield: element
sep ||= lambda { comma_breakable }
first = true
- list.__send__(iter_method) {|*v|
+ list.__send__(iter_method) {|v|
if first
first = false
else
sep.call
end
- yield(*v)
+ yield(v)
}
end