diff options
author | ryan <ryan@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-06-01 03:45:05 +0000 |
---|---|---|
committer | ryan <ryan@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-06-01 03:45:05 +0000 |
commit | d22130922e7842226d38d59680e4bbb48a28a5f0 (patch) | |
tree | 39594d3a14641dd5488a99a5e633239296fa5742 /lib/rubygems/platform.rb | |
parent | 4752539e3f3e563d559732c52424206bd6f12dbd (diff) | |
download | ruby-d22130922e7842226d38d59680e4bbb48a28a5f0.tar.gz |
Import rubygems 1.8.5 (released @ 137c80f)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31885 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rubygems/platform.rb')
-rw-r--r-- | lib/rubygems/platform.rb | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/lib/rubygems/platform.rb b/lib/rubygems/platform.rb index b6608c7814..cf6db7c16d 100644 --- a/lib/rubygems/platform.rb +++ b/lib/rubygems/platform.rb @@ -4,6 +4,8 @@ # File a patch instead and assign it to Ryan Davis or Eric Hodel. ###################################################################### +require "rubygems/deprecate" + ## # Available list of platforms for targeting Gem installations. @@ -121,8 +123,13 @@ class Gem::Platform # the same CPU, OS and version. def ==(other) - self.class === other and - @cpu == other.cpu and @os == other.os and @version == other.version + self.class === other and to_a == other.to_a + end + + alias :eql? :== + + def hash # :nodoc: + to_a.hash end ## @@ -185,5 +192,8 @@ class Gem::Platform CURRENT = 'current' + extend Deprecate + + deprecate :empty?, :none, 2011, 11 end |