diff options
author | drbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-08-26 20:24:51 +0000 |
---|---|---|
committer | drbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-08-26 20:24:51 +0000 |
commit | e487a7f53cffbadf0bf15ff169c9cb5898503250 (patch) | |
tree | eaa80eb4ced6fcdcc8b327d1cc5e47f66703fd1b /lib/rubygems/core_ext | |
parent | cddd93a57568966b416e300529bdffc0c7e87b51 (diff) | |
download | ruby-e487a7f53cffbadf0bf15ff169c9cb5898503250.tar.gz |
* lib/rubygems: Import RubyGems 2.1.0 Release Candidate
* test/rubygems: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42693 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rubygems/core_ext')
-rwxr-xr-x | lib/rubygems/core_ext/kernel_require.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/rubygems/core_ext/kernel_require.rb b/lib/rubygems/core_ext/kernel_require.rb index b9172e26c0..3619f3f559 100755 --- a/lib/rubygems/core_ext/kernel_require.rb +++ b/lib/rubygems/core_ext/kernel_require.rb @@ -8,6 +8,8 @@ require 'monitor' module Kernel + RUBYGEMS_ACTIVATION_MONITOR = Monitor.new # :nodoc: + if defined?(gem_original_require) then # Ruby ships with a custom_require, override its require remove_method :require @@ -33,10 +35,8 @@ module Kernel # The normal <tt>require</tt> functionality of returning false if # that file has already been loaded is preserved. - ACTIVATION_MONITOR = Monitor.new - def require path - ACTIVATION_MONITOR.enter + RUBYGEMS_ACTIVATION_MONITOR.enter spec = Gem.find_unresolved_default_spec(path) if spec @@ -118,7 +118,7 @@ module Kernel raise load_error ensure - ACTIVATION_MONITOR.exit + RUBYGEMS_ACTIVATION_MONITOR.exit end private :require |