pry/pry — Issue #302: show-method raises an error if source_location is buggy
Author: ConradIrwin
Created: 2011-10-18 02:21:25+00:00
State: open

[2] pry(main)> require 'yajl/json_gem'
DEPRECATION WARNING: Yajl's JSON gem compatibility API is going to be removed in 2.0
=> true
[3] pry(main)> show-method Hash#to_json
EOFError: end of file reached
from /home/conrad/.rvm/gems/ree-1.8.7-2011.03@pry/gems/method_source-0.6.6/lib/method_source.rb:57:in `readline'

For some reason Hash.instance_method(:to_json).source_location indicates it is to be found on the very last line of its file...