Skip to content

Instantly share code, notes, and snippets.

@aaronblohowiak
Created April 24, 2009 05:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aaronblohowiak/100964 to your computer and use it in GitHub Desktop.
Save aaronblohowiak/100964 to your computer and use it in GitHub Desktop.
def inspect_it(name, thing)
%w{to_s class inspect}.each do |m|
print "#{name}.#{m}: "+ thing.send(m.to_sym)+"\n"
end
end
set_trace_func proc { |event, file, line, id, binding, classname|
%w{event file line id binding classname}.each do |arg|
inspect_it(arg, eval(arg))
end
printf "%8s %s:%-2d %10s %8s\n", event, file, line, id, classname
}
class Aaron;end;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment