From c480dd39a968e65fc432e0fe278dae1036c29afb Mon Sep 17 00:00:00 2001 From: Shaun Jackman Date: Mon, 13 Aug 2018 23:38:48 -0700 Subject: [PATCH] Warn if os/linux is loaded on generic OS --- Library/Homebrew/os/linux.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Library/Homebrew/os/linux.rb b/Library/Homebrew/os/linux.rb index e5af301b2f..f78a675422 100644 --- a/Library/Homebrew/os/linux.rb +++ b/Library/Homebrew/os/linux.rb @@ -5,6 +5,8 @@ module OS ::MacOS = self # rubocop:disable Naming/ConstantName + raise "Loaded OS::Linux on generic OS!" if ENV["HOMEBREW_TEST_GENERIC_OS"] + def prefer_64_bit? Hardware::CPU.is_64_bit? end