summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHiroshi SHIBATA <[email protected]>2023-03-16 12:55:30 +0900
committerHiroshi SHIBATA <[email protected]>2023-03-17 18:50:55 +0900
commit83f9aa8f02c9fdcf8d22f0859c4f4fb3ad30bb42 ()
tree0960c81245f3f30debb003255800f33901e168f3
parentf4d1f660d0c60072813fa46b0e704561ff8e20fe (diff)
[rubygems/rubygems] util/rubocop -A --only Style/Alias
https://.com/rubygems/rubygems/commit/fba6e94de9
-rw-r--r--lib/rubygems/commands/query_command.rb2
-rw-r--r--lib/rubygems/core_ext/kernel_require.rb2
-rw-r--r--lib/rubygems/dependency.rb2
-rw-r--r--lib/rubygems/errors.rb2
-rw-r--r--lib/rubygems/exceptions.rb2
-rw-r--r--lib/rubygems/name_tuple.rb2
-rw-r--r--lib/rubygems/package/tar_reader.rb2
-rw-r--r--lib/rubygems/package/tar_reader/entry.rb2
-rw-r--r--lib/rubygems/platform.rb2
-rw-r--r--lib/rubygems/remote_fetcher.rb2
-rw-r--r--lib/rubygems/request_set/gem_dependency_api.rb2
-rw-r--r--lib/rubygems/request_set/lockfile/tokenizer.rb2
-rw-r--r--lib/rubygems/requirement.rb4
-rw-r--r--lib/rubygems/security/policy.rb2
-rw-r--r--lib/rubygems/specification.rb8
-rw-r--r--lib/rubygems/version.rb2
-rw-r--r--test/rubygems/test_gem_ext_builder.rb4
-rw-r--r--test/rubygems/test_gem_specification.rb4
-rw-r--r--test/rubygems/test_require.rb4
19 files changed, 26 insertions, 26 deletions
@@ -9,7 +9,7 @@ class Gem::Commands::QueryCommand < Gem::Command
include Gem::QueryUtils
- alias warning_without_suggested_alternatives deprecation_warning
def deprecation_warning
warning_without_suggested_alternatives
@@ -13,7 +13,7 @@ module Kernel
# Make sure we have a reference to Ruby's original Kernel#require
unless defined?(gem_original_require)
# :stopdoc:
- alias gem_original_require require
private :gem_original_require
# :startdoc:
end
@@ -204,7 +204,7 @@ class Gem::Dependency
requirement.satisfied_by? version
end
- alias === =~
##
# :call-seq:
@@ -174,6 +174,6 @@ module Gem
##
# The "exception" alias allows you to call raise on a SourceFetchProblem.
- alias exception error
end
end
@@ -222,7 +222,7 @@ class Gem::SystemExitException < SystemExit
##
# The exit code for the process
- alias exit_code status
##
# Creates a new SystemExitException with the given +exit_code+
@@ -86,7 +86,7 @@ class Gem::NameTuple
"#<Gem::NameTuple #{@name}, #{@version}, #{@platform}>"
end
- alias to_s inspect # :nodoc:
def <=>(other)
[@name, @version, Gem::Platform.sort_priority(@platform)] <=>
@@ -62,7 +62,7 @@ class Gem::Package::TarReader
end
end
- alias each_entry each
##
# NOTE: Do not call #rewind during #each
@@ -151,7 +151,7 @@ class Gem::Package::TarReader::Entry
@header.size
end
- alias length size
##
# Reads +len+ bytes from the tar file entry, or the rest of the entry if
@@ -141,7 +141,7 @@ class Gem::Platform
self.class === other && to_a == other.to_a
end
- alias :eql? :==
def hash # :nodoc:
to_a.hash
@@ -233,7 +233,7 @@ class Gem::RemoteFetcher
end
end
- alias :fetch_https :fetch_http
##
# Downloads +uri+ and returns it as a String.
@@ -767,7 +767,7 @@ Gem dependencies file #{@path} includes git reference for both ref/branch and ta
# Block form for restricting gems to a particular set of platforms. See
# #platform.
- alias :platforms :platform
##
# :category: Gem Dependencies DSL
@@ -48,7 +48,7 @@ class Gem::RequestSet::Lockfile::Tokenizer
def next_token
@tokens.shift
end
- alias :shift :next_token
def peek
@tokens.first || EOF
@@ -244,8 +244,8 @@ class Gem::Requirement
requirements.all? {|op, rv| OPS[op].call version, rv }
end
- alias :=== :satisfied_by?
- alias :=~ :satisfied_by?
##
# True if the requirement will not always match the latest version.
@@ -287,5 +287,5 @@ class Gem::Security::Policy
true
end
- alias to_s name # :nodoc:
end
@@ -735,7 +735,7 @@ class Gem::Specification < Gem::BasicSpecification
attr_accessor :activated
- alias :activated? :activated
##
# Autorequire was used by old RubyGems to automatically require a file.
@@ -1546,7 +1546,7 @@ class Gem::Specification < Gem::BasicSpecification
private :add_dependency_with_type
- alias add_dependency add_runtime_dependency
##
# Adds this spec's require paths to LOAD_PATH, in the proper location.
@@ -1991,7 +1991,7 @@ class Gem::Specification < Gem::BasicSpecification
end
rubygems_deprecate :has_rdoc=
- alias :has_rdoc? :has_rdoc # :nodoc:
rubygems_deprecate :has_rdoc?
##
@@ -2002,7 +2002,7 @@ class Gem::Specification < Gem::BasicSpecification
end
# :stopdoc:
- alias has_test_suite? has_unit_tests?
# :startdoc:
def hash # :nodoc:
@@ -165,7 +165,7 @@ class Gem::Version
@version.dup
end
- alias to_s version
##
# True if the +version+ string matches RubyGems' requirements.
@@ -153,7 +153,7 @@ install:
def test_build_extensions_install_ext_only
class << Gem
- alias orig_install_extension_in_lib install_extension_in_lib
remove_method :install_extension_in_lib
@@ -199,7 +199,7 @@ install:
class << Gem
remove_method :install_extension_in_lib
- alias install_extension_in_lib orig_install_extension_in_lib
end
end
@@ -1704,7 +1704,7 @@ dependencies: []
RbConfig::CONFIG["ENABLE_SHARED"], "no"
class << Gem
- alias orig_default_ext_dir_for default_ext_dir_for
remove_method :default_ext_dir_for
@@ -1726,7 +1726,7 @@ dependencies: []
class << Gem
remove_method :default_ext_dir_for
- alias default_ext_dir_for orig_default_ext_dir_for
end
end
@@ -541,7 +541,7 @@ class TestGemRequire < Gem::TestCase
def test_try_activate_error_unlocks_require_monitor
silence_warnings do
class << ::Gem
- alias old_try_activate try_activate
def try_activate(*); raise "raised from try_activate"; end
end
end
@@ -553,7 +553,7 @@ class TestGemRequire < Gem::TestCase
ensure
silence_warnings do
class << ::Gem
- alias try_activate old_try_activate
end
end
Kernel::RUBYGEMS_ACTIVATION_MONITOR.exit