From af8091a27984659f2c14f64ee0ba3594e219c32c Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Mon, 20 Apr 2020 10:27:12 +0100 Subject: [PATCH] Remove ARGV_WITHOUT_MONKEY_PATCHING Our usage of `ARGV` will go away soon enough and maintaining state between `ARGV` and `ARGV_WITHOUT_MONKEY_PATCHING` is futile. Fixes #7397 --- Library/Homebrew/cli/args.rb | 2 +- Library/Homebrew/global.rb | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/Library/Homebrew/cli/args.rb b/Library/Homebrew/cli/args.rb index 4879c4f6bc..765e9d2963 100644 --- a/Library/Homebrew/cli/args.rb +++ b/Library/Homebrew/cli/args.rb @@ -13,7 +13,7 @@ module Homebrew super self[:remaining] = [] - self[:cmdline_args] = ARGV_WITHOUT_MONKEY_PATCHING.dup + self[:cmdline_args] = ARGV.dup.freeze @args_parsed = false @processed_options = [] diff --git a/Library/Homebrew/global.rb b/Library/Homebrew/global.rb index 1fc0cb0a54..6e9aefb675 100644 --- a/Library/Homebrew/global.rb +++ b/Library/Homebrew/global.rb @@ -40,7 +40,6 @@ require "cli/args" require "messages" require "system_command" -ARGV_WITHOUT_MONKEY_PATCHING = ARGV.dup.freeze ARGV.extend(HomebrewArgvExtension) HOMEBREW_PRODUCT = ENV["HOMEBREW_PRODUCT"]