diff options
Diffstat (limited to 'Library/Homebrew/extend')
| -rw-r--r-- | Library/Homebrew/extend/ENV/std.rb | 16 | ||||
| -rw-r--r-- | Library/Homebrew/extend/ENV/super.rb | 24 | ||||
| -rw-r--r-- | Library/Homebrew/extend/fileutils.rb | 4 | ||||
| -rw-r--r-- | Library/Homebrew/extend/os/linux/hardware/cpu.rb | 2 | ||||
| -rw-r--r-- | Library/Homebrew/extend/os/mac/development_tools.rb | 2 | ||||
| -rw-r--r-- | Library/Homebrew/extend/os/mac/extend/ENV/super.rb | 4 | ||||
| -rw-r--r-- | Library/Homebrew/extend/os/mac/utils/bottles.rb | 2 | ||||
| -rw-r--r-- | Library/Homebrew/extend/pathname.rb | 6 | ||||
| -rw-r--r-- | Library/Homebrew/extend/string.rb | 2 |
9 files changed, 31 insertions, 31 deletions
diff --git a/Library/Homebrew/extend/ENV/std.rb b/Library/Homebrew/extend/ENV/std.rb index c1111b840..68bc9499d 100644 --- a/Library/Homebrew/extend/ENV/std.rb +++ b/Library/Homebrew/extend/ENV/std.rb @@ -53,7 +53,7 @@ module Stdenv append_path "PATH", gcc_formula.opt_bin.to_s end end - alias_method :generic_setup_build_environment, :setup_build_environment + alias generic_setup_build_environment setup_build_environment def homebrew_extra_pkg_config_paths [] @@ -84,7 +84,7 @@ module Stdenv old end - alias_method :j1, :deparallelize + alias j1 deparallelize # These methods are no-ops for compatibility. %w[fast O4 Og].each { |opt| define_method(opt) {} } @@ -112,13 +112,13 @@ module Stdenv super set_cpu_cflags "-march=nocona -mssse3" end - alias_method :gcc_4_0_1, :gcc_4_0 + alias gcc_4_0_1 gcc_4_0 def gcc super set_cpu_cflags end - alias_method :gcc_4_2, :gcc + alias gcc_4_2 gcc GNU_GCC_VERSIONS.each do |n| define_method(:"gcc-#{n}") do @@ -139,19 +139,19 @@ module Stdenv def minimal_optimization set_cflags "-Os #{SAFE_CFLAGS_FLAGS}" end - alias_method :generic_minimal_optimization, :minimal_optimization + alias generic_minimal_optimization minimal_optimization def no_optimization set_cflags SAFE_CFLAGS_FLAGS end - alias_method :generic_no_optimization, :no_optimization + alias generic_no_optimization no_optimization def libxml2 end def x11 end - alias_method :libpng, :x11 + alias libpng x11 # we've seen some packages fail to build when warnings are disabled! def enable_warnings @@ -224,7 +224,7 @@ module Stdenv append flags, xarch unless xarch.empty? append flags, map.fetch(effective_arch, default) end - alias_method :generic_set_cpu_flags, :set_cpu_flags + alias generic_set_cpu_flags set_cpu_flags # @private def effective_arch diff --git a/Library/Homebrew/extend/ENV/super.rb b/Library/Homebrew/extend/ENV/super.rb index 39ff4b8f8..1c0271685 100644 --- a/Library/Homebrew/extend/ENV/super.rb +++ b/Library/Homebrew/extend/ENV/super.rb @@ -18,7 +18,7 @@ module Superenv attr_accessor :keg_only_deps, :deps attr_accessor :x11 - alias_method :x11?, :x11 + alias x11? x11 def self.extended(base) base.keg_only_deps = [] @@ -82,7 +82,7 @@ module Superenv # s - apply fix for sed's Unicode support # a - apply fix for apr-1-config path end - alias_method :generic_setup_build_environment, :setup_build_environment + alias generic_setup_build_environment setup_build_environment private @@ -263,7 +263,7 @@ module Superenv old end - alias_method :j1, :deparallelize + alias j1 deparallelize def make_jobs self["MAKEFLAGS"] =~ /-\w*j(\d+)/ @@ -334,18 +334,18 @@ module Superenv # These methods are no longer necessary under superenv, but are needed to # maintain an interface compatible with stdenv. - alias_method :fast, :noop - alias_method :O4, :noop - alias_method :Og, :noop - alias_method :libxml2, :noop - alias_method :set_cpu_flags, :noop + alias fast noop + alias O4 noop + alias Og noop + alias libxml2 noop + alias set_cpu_flags noop # These methods provide functionality that has not yet been ported to # superenv. - alias_method :gcc_4_0_1, :noop - alias_method :minimal_optimization, :noop - alias_method :no_optimization, :noop - alias_method :enable_warnings, :noop + alias gcc_4_0_1 noop + alias minimal_optimization noop + alias no_optimization noop + alias enable_warnings noop end class Array diff --git a/Library/Homebrew/extend/fileutils.rb b/Library/Homebrew/extend/fileutils.rb index d5bc3e6d7..b889f9ded 100644 --- a/Library/Homebrew/extend/fileutils.rb +++ b/Library/Homebrew/extend/fileutils.rb @@ -84,7 +84,7 @@ module FileUtils end # @private - alias_method :old_mkdir, :mkdir + alias old_mkdir mkdir # A version of mkdir that also changes to that folder in a block. def mkdir(name, &_block) @@ -122,7 +122,7 @@ module FileUtils if method_defined?(:ruby) # @private - alias_method :old_ruby, :ruby + alias old_ruby ruby end # Run the `ruby` Homebrew is using rather than whatever is in the `PATH`. diff --git a/Library/Homebrew/extend/os/linux/hardware/cpu.rb b/Library/Homebrew/extend/os/linux/hardware/cpu.rb index 2e5b3d07d..2472c60ed 100644 --- a/Library/Homebrew/extend/os/linux/hardware/cpu.rb +++ b/Library/Homebrew/extend/os/linux/hardware/cpu.rb @@ -81,7 +81,7 @@ module Hardware %w[aes altivec avx avx2 lm sse3 ssse3 sse4 sse4_2].each do |flag| define_method(flag + "?") { flags.include? flag } end - alias_method :is_64_bit?, :lm? + alias is_64_bit? lm? def bits is_64_bit? ? 64 : 32 diff --git a/Library/Homebrew/extend/os/mac/development_tools.rb b/Library/Homebrew/extend/os/mac/development_tools.rb index b9c9d8e43..381b26e66 100644 --- a/Library/Homebrew/extend/os/mac/development_tools.rb +++ b/Library/Homebrew/extend/os/mac/development_tools.rb @@ -3,7 +3,7 @@ require "os/mac/xcode" # @private class DevelopmentTools class << self - alias_method :original_locate, :locate + alias original_locate locate def locate(tool) (@locate ||= {}).fetch(tool) do |key| @locate[key] = if (located_tool = original_locate(tool)) diff --git a/Library/Homebrew/extend/os/mac/extend/ENV/super.rb b/Library/Homebrew/extend/os/mac/extend/ENV/super.rb index 78e36251c..38a81488f 100644 --- a/Library/Homebrew/extend/os/mac/extend/ENV/super.rb +++ b/Library/Homebrew/extend/os/mac/extend/ENV/super.rb @@ -118,6 +118,6 @@ module Superenv # These methods are no longer necessary under superenv, but are needed to # maintain an interface compatible with stdenv. - alias_method :macosxsdk, :noop - alias_method :remove_macosxsdk, :noop + alias macosxsdk noop + alias remove_macosxsdk noop end diff --git a/Library/Homebrew/extend/os/mac/utils/bottles.rb b/Library/Homebrew/extend/os/mac/utils/bottles.rb index 6b83ad6c4..accfc6a59 100644 --- a/Library/Homebrew/extend/os/mac/utils/bottles.rb +++ b/Library/Homebrew/extend/os/mac/utils/bottles.rb @@ -21,7 +21,7 @@ module Utils class Collector private - alias_method :original_find_matching_tag, :find_matching_tag + alias original_find_matching_tag find_matching_tag def find_matching_tag(tag) original_find_matching_tag(tag) || find_altivec_tag(tag) || find_or_later_tag(tag) end diff --git a/Library/Homebrew/extend/pathname.rb b/Library/Homebrew/extend/pathname.rb index 68029dc38..3f73b6a1c 100644 --- a/Library/Homebrew/extend/pathname.rb +++ b/Library/Homebrew/extend/pathname.rb @@ -132,7 +132,7 @@ class Pathname if method_defined?(:write) # @private - alias_method :old_write, :write + alias old_write write end # we assume this pathname object is a file obviously @@ -212,7 +212,7 @@ class Pathname end # @private - alias_method :extname_old, :extname + alias extname_old extname # extended to support common double extensions def extname(path = to_s) @@ -322,7 +322,7 @@ class Pathname end # FIXME: eliminate the places where we rely on this method - alias_method :to_str, :to_s unless method_defined?(:to_str) + alias to_str to_s unless method_defined?(:to_str) def cd Dir.chdir(self) { yield } diff --git a/Library/Homebrew/extend/string.rb b/Library/Homebrew/extend/string.rb index 1d9c2e036..bd5994fe1 100644 --- a/Library/Homebrew/extend/string.rb +++ b/Library/Homebrew/extend/string.rb @@ -13,7 +13,7 @@ class String # sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt # mollit anim id est laborum. # EOS - alias_method :undent_________________________________________________________72, :undent + alias undent_________________________________________________________72 undent # String.chomp, but if result is empty: returns nil instead. # Allows `chuzzle || foo` short-circuits. |
