From 2064b30fceb8d9e3fe025331919b8feebf33ff7f Mon Sep 17 00:00:00 2001 From: follower Date: Wed, 24 Apr 2019 15:02:13 +1200 Subject: [PATCH] Fix check_for_unsupported_macos() on outdated releases Recent commit https://github.com/Homebrew/brew/commit/36dbad3922ad984f7c396a9757fe8ae9750c44b0 to default to frozen string literals (via `frozen_string_literal`) broke `check_for_unsupported_macos()` on outdated releases--due to attempted modification of a frozen string literal. This breaks `install` and `doctor`. It's like the change wasn't tested on an unsupported outdated release or something... :D Adding a `+` prefix is apparently one way around this issue according to https://stackoverflow.com/questions/37799296/what-does-the-comment-frozen-string-literal-true-do#37799399. The change worked for me. --- Library/Homebrew/extend/os/mac/diagnostic.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/extend/os/mac/diagnostic.rb b/Library/Homebrew/extend/os/mac/diagnostic.rb index ae16cf5624..53cf3cd724 100644 --- a/Library/Homebrew/extend/os/mac/diagnostic.rb +++ b/Library/Homebrew/extend/os/mac/diagnostic.rb @@ -51,7 +51,7 @@ module Homebrew if OS::Mac.prerelease? what = "pre-release version" elsif OS::Mac.outdated_release? - who << " (and Apple)" + +who << " (and Apple)" what = "old version" else return