From 1eecf1ac0bcf8b1c3c76defab7d27be97c493f0d Mon Sep 17 00:00:00 2001 From: Jack Nagel Date: Wed, 6 Aug 2014 09:56:09 -0500 Subject: [PATCH] Don't use Hash#first Fixes Homebrew/homebrew#31360. --- Library/Homebrew/compilers.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/compilers.rb b/Library/Homebrew/compilers.rb index 55f8c3fe0d..7080f69e7a 100644 --- a/Library/Homebrew/compilers.rb +++ b/Library/Homebrew/compilers.rb @@ -31,7 +31,7 @@ class CompilerFailure def self.create(spec, &block) # Non-Apple compilers are in the format fails_with compiler => version if spec.is_a?(Hash) - _, major_version = spec.first + _, major_version = spec.each { |e| break e } name = "gcc-#{major_version}" # so fails_with :gcc => '4.8' simply marks all 4.8 releases incompatible version = "#{major_version}.999"