From: Josh Cheek Date: 2011-06-14T18:57:15+09:00 Subject: Re: A way to find out when a constant gets defined? --0016e644c73068261104a5a90f96 Content-Type: text/plain; charset=ISO-8859-1 On Tue, Jun 14, 2011 at 4:52 AM, Ryan Davis wrote: > > On Jun 14, 2011, at 02:32 , Josh Cheek wrote: > > > # When I load irb with my app, Psych is somehow defined > > $ bundle exec irb > > ruby-1.9.2-p180 :001 > Psych > > => Psych > > ruby-1.9.2-p180 :002 > exit > > 6478 % gem19 which psych > /Users/ryan/.multiruby/install/1.9.2-p136/lib/ruby/1.9.1/psych > > >> require 'psych' > => true > >> $".grep(/psych/i).map { |s| File.dirname File.dirname s }.uniq > => ["/Users/ryan/.multiruby/install/1.9.2-p136/lib/ruby/1.9.1", > "/Users/ryan/.multiruby/install/1.9.2-p136/lib/ruby/1.9.1/psych", > "/Users/ryan/.multiruby/install/1.9.2-p136/lib/ruby"] > > Psych ships with 1.9 > > > # Hmm. Yes, I have it too: $ gem which psych /Users/josh/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/psych # But why can't I access it? $ ruby -e 'require "psych"' :29:in `require': no such file to load -- psych (LoadError) from :29:in `require' from -e:1:in `
' --0016e644c73068261104a5a90f96--