1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00

fix top-level prompt for 1.8.7

This commit is contained in:
Ryan Fitzgerald 2011-09-08 23:12:26 -07:00
parent 3d91fc4f20
commit 464d0991b2

View file

@ -106,7 +106,7 @@ class Pry
obj.name.to_s obj.name.to_s
elsif TOPLEVEL_BINDING.eval('self') == obj elsif TOPLEVEL_BINDING.eval('self') == obj
# special case for 'main' object :) # special case for 'main' object :)
obj.inspect obj.to_s
elsif [String, Numeric, Symbol, nil, true, false].any? { |v| v === obj } && obj.inspect.length <= max_length elsif [String, Numeric, Symbol, nil, true, false].any? { |v| v === obj } && obj.inspect.length <= max_length
obj.inspect obj.inspect
else else