aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/tab.rb
diff options
context:
space:
mode:
authorJack Nagel2014-08-03 18:17:12 -0500
committerJack Nagel2014-08-03 18:17:49 -0500
commit3e8b0fc250b5f921779194af20f693894987eba9 (patch)
treeb5237d1d71ff462103756939ddd9a0749b638aad /Library/Homebrew/tab.rb
parent4d0e6ca17e0093636ccf255bfc241bd14b799e1c (diff)
downloadhomebrew-3e8b0fc250b5f921779194af20f693894987eba9.tar.bz2
Add predicate methods to Tab to match BuildOptions
Diffstat (limited to 'Library/Homebrew/tab.rb')
-rw-r--r--Library/Homebrew/tab.rb14
1 files changed, 11 insertions, 3 deletions
diff --git a/Library/Homebrew/tab.rb b/Library/Homebrew/tab.rb
index 436af0062..93ee8fd37 100644
--- a/Library/Homebrew/tab.rb
+++ b/Library/Homebrew/tab.rb
@@ -83,9 +83,9 @@ class Tab < OpenStruct
def with? name
if options.include? "with-#{name}"
- used_options.include? "with-#{name}"
+ include? "with-#{name}"
elsif options.include? "without-#{name}"
- not used_options.include? "without-#{name}"
+ not include? "without-#{name}"
else
false
end
@@ -100,7 +100,15 @@ class Tab < OpenStruct
end
def universal?
- used_options.include? "universal"
+ include?("universal")
+ end
+
+ def cxx11?
+ include?("c++11")
+ end
+
+ def build_32_bit?
+ include?("32-bit")
end
def used_options