Guest User

Untitled

a guest
May 16th, 2018
137
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.33 KB | None | 0 0
  1. #!/usr/bin/env ruby
  2. require 'pp'
  3. %w{Hash NilClass Object Range Regexp String Symbol Time}.each do |c|
  4. class Kernel.module_eval(c); alias_method :old_inspect, :inspect; def inspect; "#{self.class.name}(#{size rescue 'n/a'}) #{old_inspect}"; end; end
  5. end
  6. pp Hash.new, nil, Object.new, /fest/, 'fest', Struct.new(:fest), :fest, Time.new, 1
Add Comment
Please, Sign In to add comment