diff options
author | drbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-12-07 00:53:01 +0000 |
---|---|---|
committer | drbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-12-07 00:53:01 +0000 |
commit | 97f80207d0f0d13f28a419d8c92e96bb9064096a () | |
tree | de416fff9bbc978434cb4c1185099151df2ac27c /lib/rubygems/stub_specification.rb | |
parent | a0b80a44101708b5d66cdd87f16c98277954a77c (diff) |
* lib/rubygems: Update to RubyGems 2.4.5.
* test/rubygems: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48729 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | lib/rubygems/stub_specification.rb | 16 |
1 files changed, 11 insertions, 5 deletions
@@ -42,6 +42,7 @@ class Gem::StubSpecification < Gem::BasicSpecification self.loaded_from = filename @data = nil @extensions = nil @spec = nil end @@ -49,8 +50,11 @@ class Gem::StubSpecification < Gem::BasicSpecification # True when this gem has been activated def activated? - loaded = Gem.loaded_specs[name] - loaded && loaded.version == version end def build_extensions # :nodoc: @@ -154,9 +158,11 @@ class Gem::StubSpecification < Gem::BasicSpecification # The full Gem::Specification for this gem, loaded from evalling its gemspec def to_spec - @spec ||= Gem.loaded_specs.values.find { |spec| - spec.name == @name and spec.version == @version - } @spec ||= Gem::Specification.load(loaded_from) @spec.ignored = @ignored if instance_variable_defined? :@ignored |