[rubygems/rubygems] Deprecate Gem::Platform.match

e3ba3e2225
This commit is contained in:
Hiroshi SHIBATA 2023-04-04 11:53:11 +09:00 committed by git
parent f602cb55d7
commit 7fdf98ef39
2 changed files with 9 additions and 2 deletions

View file

@ -22,6 +22,11 @@ class Gem::Platform
match_platforms?(platform, Gem.platforms)
end
class << self
extend Gem::Deprecate
rubygems_deprecate :match, "Gem::Platform.match_spec? or match_gem?"
end
def self.match_platforms?(platform, platforms)
platform = Gem::Platform.new(platform) unless platform.is_a?(Gem::Platform)
platforms.any? do |local_platform|