From ce67dc3e63afaba331e62fd25b920a1c60640051 Mon Sep 17 00:00:00 2001 From: Jonathan Chang Date: Fri, 20 Nov 2020 21:51:07 +1100 Subject: [PATCH 1/2] formula_installer: fix type for fetch_dependency This receives a Dependency, not a Formula. --- Library/Homebrew/formula_installer.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Library/Homebrew/formula_installer.rb b/Library/Homebrew/formula_installer.rb index ee2d2b0218..be714073e8 100644 --- a/Library/Homebrew/formula_installer.rb +++ b/Library/Homebrew/formula_installer.rb @@ -654,7 +654,7 @@ class FormulaInstaller @show_header = true unless deps.empty? end - sig { params(dep: Formula).void } + sig { params(dep: Dependency).void } def fetch_dependency(dep) df = dep.to_formula fi = FormulaInstaller.new( @@ -675,7 +675,7 @@ class FormulaInstaller fi.fetch end - sig { params(dep: Formula, inherited_options: Options).void } + sig { params(dep: Dependency, inherited_options: Options).void } def install_dependency(dep, inherited_options) df = dep.to_formula tab = Tab.for_formula(df) From 7330b4a6cc8270628309b463977d5ea4ae178ed0 Mon Sep 17 00:00:00 2001 From: Jonathan Chang Date: Fri, 20 Nov 2020 22:20:34 +1100 Subject: [PATCH 2/2] tap_auditor: widen type for constructor We don't always pass `--strict`. --- Library/Homebrew/tap_auditor.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/tap_auditor.rb b/Library/Homebrew/tap_auditor.rb index c38e9abaf6..d8294815f2 100644 --- a/Library/Homebrew/tap_auditor.rb +++ b/Library/Homebrew/tap_auditor.rb @@ -10,7 +10,7 @@ module Homebrew attr_reader :name, :path, :tap_audit_exceptions, :problems - sig { params(tap: Tap, strict: T::Boolean).void } + sig { params(tap: Tap, strict: T.nilable(T::Boolean)).void } def initialize(tap, strict:) @name = tap.name @path = tap.path