From 1f3bbe64e0df2535a7dd240e05b7741d28bdf267 Mon Sep 17 00:00:00 2001 From: Jack Nagel Date: Fri, 12 Sep 2014 21:27:00 -0500 Subject: Make parameter names match superclass parameter names --- Library/Homebrew/exceptions.rb | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'Library') diff --git a/Library/Homebrew/exceptions.rb b/Library/Homebrew/exceptions.rb index 9cb0fcb9c..b74234c35 100644 --- a/Library/Homebrew/exceptions.rb +++ b/Library/Homebrew/exceptions.rb @@ -113,12 +113,12 @@ class UnsatisfiedRequirements < Homebrew::InstallationError end class FormulaConflictError < Homebrew::InstallationError - attr_reader :f, :conflicts + attr_reader :conflicts - def initialize(f, conflicts) - @f = f + def initialize(formula, conflicts) @conflicts = conflicts - super f, message + @formula = formula + super formula, message end def conflict_message(conflict) @@ -130,7 +130,7 @@ class FormulaConflictError < Homebrew::InstallationError def message message = [] - message << "Cannot install #{f.name} because conflicting formulae are installed.\n" + message << "Cannot install #{formula.name} because conflicting formulae are installed.\n" message.concat conflicts.map { |c| conflict_message(c) } << "" message << <<-EOS.undent Please `brew unlink #{conflicts.map(&:name)*' '}` before continuing. @@ -204,9 +204,9 @@ end # raised by CompilerSelector if the formula fails with all of # the compilers available on the user's system class CompilerSelectionError < Homebrew::InstallationError - def initialize f - super f, <<-EOS.undent - #{f.name} cannot be built with any available compilers. + def initialize formula + super formula, <<-EOS.undent + #{formula.name} cannot be built with any available compilers. To install this formula, you may need to: brew install gcc EOS -- cgit v1.2.3