From 1a6467eeeab8887ff404ff87b8b15d6c50c0525c Mon Sep 17 00:00:00 2001 From: vidusheeamoli Date: Tue, 21 Jul 2020 23:45:34 +0530 Subject: [PATCH 1/3] Gemfile: set sorbet version --- Library/Homebrew/Gemfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Library/Homebrew/Gemfile b/Library/Homebrew/Gemfile index e6a4fdb19b..4645c24044 100644 --- a/Library/Homebrew/Gemfile +++ b/Library/Homebrew/Gemfile @@ -14,8 +14,8 @@ gem "rspec-wait", require: false gem "rubocop" gem "simplecov", require: false if ENV["HOMEBREW_SORBET"] - gem "sorbet" - gem "sorbet-runtime" + gem "sorbet", "0.5.5823" + gem "sorbet-runtime", "0.5.5823" gem "tapioca" end From 9658f011f2dbb9b539bfd7cf79bf7d93abed9339 Mon Sep 17 00:00:00 2001 From: vidusheeamoli Date: Tue, 21 Jul 2020 23:47:42 +0530 Subject: [PATCH 2/3] srb/tapioca: update rbi of recently bumped gems --- .../{codecov@0.1.17.rbi => codecov@0.2.2.rbi} | 0 .../{url@0.3.2.rbi => colorize@0.8.1.rbi} | 0 .../{zeitwerk@2.3.1.rbi => i18n@1.8.4.rbi} | 0 ...op-ast@0.1.0.rbi => rubocop-ast@0.2.0.rbi} | 18 +- ....7.0.rbi => rubocop-performance@1.7.1.rbi} | 4 + ...ec@1.41.0.rbi => rubocop-rspec@1.42.0.rbi} | 150 +++++++------ ...{rubocop@0.87.0.rbi => rubocop@0.88.0.rbi} | 200 ++++++++++++++---- .../{i18n@1.8.3.rbi => zeitwerk@2.4.0.rbi} | 2 +- 8 files changed, 263 insertions(+), 111 deletions(-) rename Library/Homebrew/sorbet/rbi/gems/{codecov@0.1.17.rbi => codecov@0.2.2.rbi} (100%) rename Library/Homebrew/sorbet/rbi/gems/{url@0.3.2.rbi => colorize@0.8.1.rbi} (100%) rename Library/Homebrew/sorbet/rbi/gems/{zeitwerk@2.3.1.rbi => i18n@1.8.4.rbi} (100%) rename Library/Homebrew/sorbet/rbi/gems/{rubocop-ast@0.1.0.rbi => rubocop-ast@0.2.0.rbi} (98%) rename Library/Homebrew/sorbet/rbi/gems/{rubocop-performance@1.7.0.rbi => rubocop-performance@1.7.1.rbi} (99%) rename Library/Homebrew/sorbet/rbi/gems/{rubocop-rspec@1.41.0.rbi => rubocop-rspec@1.42.0.rbi} (94%) rename Library/Homebrew/sorbet/rbi/gems/{rubocop@0.87.0.rbi => rubocop@0.88.0.rbi} (98%) rename Library/Homebrew/sorbet/rbi/gems/{i18n@1.8.3.rbi => zeitwerk@2.4.0.rbi} (73%) diff --git a/Library/Homebrew/sorbet/rbi/gems/codecov@0.1.17.rbi b/Library/Homebrew/sorbet/rbi/gems/codecov@0.2.2.rbi similarity index 100% rename from Library/Homebrew/sorbet/rbi/gems/codecov@0.1.17.rbi rename to Library/Homebrew/sorbet/rbi/gems/codecov@0.2.2.rbi diff --git a/Library/Homebrew/sorbet/rbi/gems/url@0.3.2.rbi b/Library/Homebrew/sorbet/rbi/gems/colorize@0.8.1.rbi similarity index 100% rename from Library/Homebrew/sorbet/rbi/gems/url@0.3.2.rbi rename to Library/Homebrew/sorbet/rbi/gems/colorize@0.8.1.rbi diff --git a/Library/Homebrew/sorbet/rbi/gems/zeitwerk@2.3.1.rbi b/Library/Homebrew/sorbet/rbi/gems/i18n@1.8.4.rbi similarity index 100% rename from Library/Homebrew/sorbet/rbi/gems/zeitwerk@2.3.1.rbi rename to Library/Homebrew/sorbet/rbi/gems/i18n@1.8.4.rbi diff --git a/Library/Homebrew/sorbet/rbi/gems/rubocop-ast@0.1.0.rbi b/Library/Homebrew/sorbet/rbi/gems/rubocop-ast@0.2.0.rbi similarity index 98% rename from Library/Homebrew/sorbet/rbi/gems/rubocop-ast@0.1.0.rbi rename to Library/Homebrew/sorbet/rbi/gems/rubocop-ast@0.2.0.rbi index e43fc405c9..42c899a54c 100644 --- a/Library/Homebrew/sorbet/rbi/gems/rubocop-ast@0.1.0.rbi +++ b/Library/Homebrew/sorbet/rbi/gems/rubocop-ast@0.2.0.rbi @@ -265,7 +265,6 @@ class RuboCop::AST::DefNode < ::RuboCop::AST::Node def arguments; end def body; end def method_name; end - def node_parts; end def receiver; end def void_context?; end end @@ -530,6 +529,7 @@ class RuboCop::AST::Node < ::Parser::AST::Node def chained?; end def child_nodes; end def class_constructor?(node = _); end + def class_definition?(node = _); end def class_type?; end def complete!; end def complete?; end @@ -570,6 +570,7 @@ class RuboCop::AST::Node < ::Parser::AST::Node def forward_arg_type?; end def forward_args_type?; end def forwarded_args_type?; end + def global_const?(node = _, param1); end def guard_clause?; end def gvar_type?; end def gvasgn_type?; end @@ -615,6 +616,7 @@ class RuboCop::AST::Node < ::Parser::AST::Node def match_with_lvasgn_type?; end def match_with_trailing_comma_type?; end def mlhs_type?; end + def module_definition?(node = _); end def module_type?; end def mrasgn_type?; end def multiline?; end @@ -679,6 +681,7 @@ class RuboCop::AST::Node < ::Parser::AST::Node def splat_type?; end def str_content(node = _); end def str_type?; end + def struct_constructor?(node = _); end def super_type?; end def sym_type?; end def true_type?; end @@ -779,6 +782,12 @@ module RuboCop::AST::NodePattern::Macros def def_node_search(method_name, pattern_str, **keyword_defaults); end end +class RuboCop::AST::NodePattern::Matcher + def initialize(&block); end + + def ===(compare); end +end + module RuboCop::AST::NumericNode def sign?; end end @@ -849,6 +858,7 @@ class RuboCop::AST::ProcessedSource def commented?(source_range); end def comments; end def comments_before_line(line); end + def contains_comment?(source_range); end def current_line(token); end def diagnostics; end def each_comment; end @@ -858,6 +868,7 @@ class RuboCop::AST::ProcessedSource def find_token; end def following_line(token); end def line_indentation(line_number); end + def line_with_comment?(line); end def lines; end def parser_error; end def path; end @@ -1034,6 +1045,7 @@ module RuboCop::AST::Traversal def on_ensure(node); end def on_erange(node); end def on_false(node); end + def on_find_pattern(node); end def on_float(node); end def on_for(node); end def on_forward_arg(node); end @@ -1199,10 +1211,14 @@ RuboCop::AST::NodePattern::Compiler::META = T.let(T.unsafe(nil), Regexp) RuboCop::AST::NodePattern::Compiler::METHOD_NAME = T.let(T.unsafe(nil), Regexp) +RuboCop::AST::NodePattern::Compiler::MULTIPLE_CUR_PLACEHOLDER = T.let(T.unsafe(nil), Regexp) + RuboCop::AST::NodePattern::Compiler::NODE = T.let(T.unsafe(nil), Regexp) RuboCop::AST::NodePattern::Compiler::NUMBER = T.let(T.unsafe(nil), Regexp) +RuboCop::AST::NodePattern::Compiler::ONLY_SEPARATOR = T.let(T.unsafe(nil), Regexp) + RuboCop::AST::NodePattern::Compiler::PARAM = T.let(T.unsafe(nil), Regexp) RuboCop::AST::NodePattern::Compiler::PARAM_CONST = T.let(T.unsafe(nil), Regexp) diff --git a/Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.7.0.rbi b/Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.7.1.rbi similarity index 99% rename from Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.7.0.rbi rename to Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.7.1.rbi index 975a4bb844..583f91b0e8 100644 --- a/Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.7.0.rbi +++ b/Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.7.1.rbi @@ -26,6 +26,10 @@ class RuboCop::Cop::Performance::BigDecimalWithNumericArgument < ::RuboCop::Cop: def autocorrect(node); end def big_decimal_with_numeric_argument?(node = _); end def on_send(node); end + + private + + def specifies_precision?(node); end end RuboCop::Cop::Performance::BigDecimalWithNumericArgument::MSG = T.let(T.unsafe(nil), String) diff --git a/Library/Homebrew/sorbet/rbi/gems/rubocop-rspec@1.41.0.rbi b/Library/Homebrew/sorbet/rbi/gems/rubocop-rspec@1.42.0.rbi similarity index 94% rename from Library/Homebrew/sorbet/rbi/gems/rubocop-rspec@1.41.0.rbi rename to Library/Homebrew/sorbet/rbi/gems/rubocop-rspec@1.42.0.rbi index dfdaf6e4ce..780df93b35 100644 --- a/Library/Homebrew/sorbet/rbi/gems/rubocop-rspec@1.41.0.rbi +++ b/Library/Homebrew/sorbet/rbi/gems/rubocop-rspec@1.42.0.rbi @@ -50,12 +50,9 @@ module RuboCop::Cop::RSpec end class RuboCop::Cop::RSpec::AlignLeftLetBrace < ::RuboCop::Cop::RSpec::Cop - def autocorrect(let); end - def investigate(_processed_source); end + extend(::RuboCop::Cop::AutoCorrector) - private - - def token_aligner; end + def on_new_investigation; end def self.autocorrect_incompatible_with; end end @@ -63,12 +60,9 @@ end RuboCop::Cop::RSpec::AlignLeftLetBrace::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::AlignRightLetBrace < ::RuboCop::Cop::RSpec::Cop - def autocorrect(let); end - def investigate(_processed_source); end + extend(::RuboCop::Cop::AutoCorrector) - private - - def token_aligner; end + def on_new_investigation; end def self.autocorrect_incompatible_with; end end @@ -105,7 +99,8 @@ end RuboCop::Cop::RSpec::Be::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::BeEql < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def eql_type_with_identity(node = _); end def on_send(node); end end @@ -123,8 +118,9 @@ module RuboCop::Cop::RSpec::Capybara end class RuboCop::Cop::RSpec::Capybara::CurrentPathExpectation < ::RuboCop::Cop::RSpec::Cop + extend(::RuboCop::Cop::AutoCorrector) + def as_is_matcher(node = _); end - def autocorrect(node); end def expectation_set_on_current_path(node = _); end def on_send(node); end def regexp_str_matcher(node = _); end @@ -132,6 +128,7 @@ class RuboCop::Cop::RSpec::Capybara::CurrentPathExpectation < ::RuboCop::Cop::RS private def add_ignore_query_options(corrector, node); end + def autocorrect(corrector, node); end def convert_regexp_str_to_literal(corrector, matcher_node, regexp_str); end def rewrite_expectation(corrector, node, to_symbol, matcher_node); end end @@ -139,8 +136,10 @@ end RuboCop::Cop::RSpec::Capybara::CurrentPathExpectation::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::Capybara::FeatureMethods < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def feature_method(node = _); end + def message(range); end def on_block(node); end def spec?(node = _); end @@ -174,7 +173,8 @@ RuboCop::Cop::RSpec::Capybara::VisibilityMatcher::MSG_FALSE = T.let(T.unsafe(nil RuboCop::Cop::RSpec::Capybara::VisibilityMatcher::MSG_TRUE = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::ContextMethod < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def context_method(node = _); end def on_block(node); end @@ -198,7 +198,7 @@ end RuboCop::Cop::RSpec::ContextWording::MSG = T.let(T.unsafe(nil), String) -class RuboCop::Cop::RSpec::Cop < ::RuboCop::Cop::Cop +class RuboCop::Cop::RSpec::Cop < ::RuboCop::Cop::Base include(::RuboCop::RSpec::Language) include(::RuboCop::RSpec::Language::NodePattern) @@ -251,8 +251,8 @@ RuboCop::Cop::RSpec::DescribeSymbol::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::DescribedClass < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def common_instance_exec_closure?(node = _); end def contains_described_class?(node0); end def described_constant(node = _); end @@ -262,6 +262,7 @@ class RuboCop::Cop::RSpec::DescribedClass < ::RuboCop::Cop::RSpec::Cop private + def autocorrect(corrector, match); end def collapse_namespace(namespace, const); end def const_name(node); end def find_usage(node, &block); end @@ -288,14 +289,10 @@ RuboCop::Cop::RSpec::DescribedClassModuleWrapping::MSG = T.let(T.unsafe(nil), St class RuboCop::Cop::RSpec::Dialect < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::MethodPreference) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def on_send(node); end def rspec_method?(node = _); end - - private - - def message(node); end end RuboCop::Cop::RSpec::Dialect::MSG = T.let(T.unsafe(nil), String) @@ -314,8 +311,8 @@ RuboCop::Cop::RSpec::EmptyExampleGroup::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::EmptyHook < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::RangeHelp) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def empty_hook?(node = _); end def on_block(node); end end @@ -326,6 +323,7 @@ class RuboCop::Cop::RSpec::EmptyLineAfterExample < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::RSpec::FinalEndLocation) include(::RuboCop::Cop::RangeHelp) include(::RuboCop::RSpec::BlankLineSeparation) + extend(::RuboCop::Cop::AutoCorrector) def allow_consecutive_one_liners?; end def allowed_one_liner?(node); end @@ -341,6 +339,7 @@ class RuboCop::Cop::RSpec::EmptyLineAfterExampleGroup < ::RuboCop::Cop::RSpec::C include(::RuboCop::RSpec::FinalEndLocation) include(::RuboCop::Cop::RangeHelp) include(::RuboCop::RSpec::BlankLineSeparation) + extend(::RuboCop::Cop::AutoCorrector) def on_block(node); end end @@ -351,6 +350,7 @@ class RuboCop::Cop::RSpec::EmptyLineAfterFinalLet < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::RSpec::FinalEndLocation) include(::RuboCop::Cop::RangeHelp) include(::RuboCop::RSpec::BlankLineSeparation) + extend(::RuboCop::Cop::AutoCorrector) def on_block(node); end end @@ -361,6 +361,7 @@ class RuboCop::Cop::RSpec::EmptyLineAfterHook < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::RSpec::FinalEndLocation) include(::RuboCop::Cop::RangeHelp) include(::RuboCop::RSpec::BlankLineSeparation) + extend(::RuboCop::Cop::AutoCorrector) def on_block(node); end end @@ -371,6 +372,7 @@ class RuboCop::Cop::RSpec::EmptyLineAfterSubject < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::RSpec::FinalEndLocation) include(::RuboCop::Cop::RangeHelp) include(::RuboCop::RSpec::BlankLineSeparation) + extend(::RuboCop::Cop::AutoCorrector) def on_block(node); end @@ -412,7 +414,8 @@ RuboCop::Cop::RSpec::ExampleWithoutDescription::MSG_ADD_DESCRIPTION = T.let(T.un RuboCop::Cop::RSpec::ExampleWithoutDescription::MSG_DEFAULT_ARGUMENT = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::ExampleWording < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def it_description(node = _); end def on_block(node); end @@ -435,7 +438,8 @@ RuboCop::Cop::RSpec::ExampleWording::MSG_SHOULD = T.let(T.unsafe(nil), String) RuboCop::Cop::RSpec::ExampleWording::SHOULD_PREFIX = T.let(T.unsafe(nil), Regexp) class RuboCop::Cop::RSpec::ExpectActual < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def expect_literal(node = _); end def on_send(node); end @@ -457,17 +461,12 @@ RuboCop::Cop::RSpec::ExpectActual::SUPPORTED_MATCHERS = T.let(T.unsafe(nil), Arr class RuboCop::Cop::RSpec::ExpectChange < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def expect_change_with_arguments(node = _); end def expect_change_with_block(node = _); end def on_block(node); end def on_send(node); end - - private - - def autocorrect_block_to_method_call(node); end - def autocorrect_method_call_to_block(node); end end RuboCop::Cop::RSpec::ExpectChange::MSG_BLOCK = T.let(T.unsafe(nil), String) @@ -505,11 +504,8 @@ module RuboCop::Cop::RSpec::ExplicitHelper private def allowed_explicit_matchers; end - def autocorrect_explicit(node); end - def autocorrect_explicit_block(node); end - def autocorrect_explicit_send(node); end def check_explicit(node); end - def corrector_explicit(to_node, actual, matcher, block_child); end + def corrector_explicit(corrector, to_node, actual, matcher, block_child); end def message_explicit(matcher); end def move_predicate(corrector, actual, matcher, block_child); end def predicate_matcher_name?(name); end @@ -525,8 +521,9 @@ module RuboCop::Cop::RSpec::FactoryBot end class RuboCop::Cop::RSpec::FactoryBot::AttributeDefinedStatically < ::RuboCop::Cop::RSpec::Cop + extend(::RuboCop::Cop::AutoCorrector) + def association?(node = _); end - def autocorrect(node); end def factory_attributes(node = _); end def on_block(node); end def value_matcher(node = _); end @@ -534,8 +531,9 @@ class RuboCop::Cop::RSpec::FactoryBot::AttributeDefinedStatically < ::RuboCop::C private def attribute_defining_method?(method_name); end - def autocorrect_replacing_parens(node); end - def autocorrect_without_parens(node); end + def autocorrect(corrector, node); end + def autocorrect_replacing_parens(corrector, node); end + def autocorrect_without_parens(corrector, node); end def braces(node); end def offensive_receiver?(receiver, node); end def proc?(attribute); end @@ -548,8 +546,8 @@ RuboCop::Cop::RSpec::FactoryBot::AttributeDefinedStatically::MSG = T.let(T.unsaf class RuboCop::Cop::RSpec::FactoryBot::CreateList < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def factory_call(node = _); end def factory_list_call(node = _); end def n_times_block_without_arg?(node = _); end @@ -602,7 +600,8 @@ class RuboCop::Cop::RSpec::FactoryBot::CreateList::TimesCorrector < ::RuboCop::C end class RuboCop::Cop::RSpec::FactoryBot::FactoryClassName < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def class_name(node = _); end def on_send(node); end @@ -655,8 +654,8 @@ RuboCop::Cop::RSpec::Focus::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::HookArgument < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def on_block(node); end def scoped_hook(node = _); end def unscoped_hook(node = _); end @@ -677,12 +676,14 @@ RuboCop::Cop::RSpec::HookArgument::HOOKS = T.let(T.unsafe(nil), String) RuboCop::Cop::RSpec::HookArgument::IMPLICIT_MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::HooksBeforeExamples < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def example_or_group?(node = _); end def on_block(node); end private + def autocorrect(corrector, node, first_example); end def check_hooks(node); end def find_first_example(node); end def multiline_block?(block); end @@ -707,8 +708,8 @@ RuboCop::Cop::RSpec::ImplicitBlockExpectation::MSG = T.let(T.unsafe(nil), String class RuboCop::Cop::RSpec::ImplicitExpect < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def implicit_expect(node = _); end def on_send(node); end @@ -726,14 +727,15 @@ RuboCop::Cop::RSpec::ImplicitExpect::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::ImplicitSubject < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def implicit_subject?(node = _); end def on_send(node); end private def allowed_by_style?(example); end + def autocorrect(corrector, node); end def valid_usage?(node); end end @@ -749,7 +751,6 @@ module RuboCop::Cop::RSpec::InflectedHelper private - def autocorrect_inflected(node); end def boolean_matcher?(node); end def check_inflected(node); end def message_inflected(predicate); end @@ -763,10 +764,15 @@ end RuboCop::Cop::RSpec::InflectedHelper::MSG_INFLECTED = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::InstanceSpy < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def have_received_usage(node0); end def null_double(node0); end def on_block(node); end + + private + + def autocorrect(corrector, node); end end RuboCop::Cop::RSpec::InstanceSpy::MSG = T.let(T.unsafe(nil), String) @@ -794,7 +800,6 @@ class RuboCop::Cop::RSpec::InvalidPredicateMatcher < ::RuboCop::Cop::RSpec::Cop private - def message(predicate); end def predicate?(name); end end @@ -802,8 +807,8 @@ RuboCop::Cop::RSpec::InvalidPredicateMatcher::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::ItBehavesLike < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def example_inclusion_offense(node = _, param1); end def on_send(node); end @@ -828,12 +833,14 @@ end RuboCop::Cop::RSpec::IteratedExpectation::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::LeadingSubject < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def check_previous_nodes(node); end def on_block(node); end private + def autocorrect(corrector, node); end def find_first_offending_node(node); end def in_spec_block?(node); end def offending?(node); end @@ -858,12 +865,14 @@ RuboCop::Cop::RSpec::LeakyConstantDeclaration::MSG_CONST = T.let(T.unsafe(nil), RuboCop::Cop::RSpec::LeakyConstantDeclaration::MSG_MODULE = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::LetBeforeExamples < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def example_or_group?(node = _); end def on_block(node); end private + def autocorrect(corrector, node, first_example); end def check_let_declarations(node); end def find_first_example(node); end def multiline_block?(block); end @@ -886,7 +895,6 @@ end RuboCop::Cop::RSpec::LetSetup::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::MessageChain < ::RuboCop::Cop::RSpec::Cop - def message(node); end def message_chain(node = _); end def on_send(node); end end @@ -965,15 +973,16 @@ RuboCop::Cop::RSpec::MultipleExpectations::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::MultipleSubjects < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::RangeHelp) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def on_block(node); end private + def autocorrect(corrector, subject); end def named_subject?(node); end - def remove_autocorrect(node); end - def rename_autocorrect(node); end + def remove_autocorrect(corrector, node); end + def rename_autocorrect(corrector, node); end end RuboCop::Cop::RSpec::MultipleSubjects::MSG = T.let(T.unsafe(nil), String) @@ -1010,8 +1019,8 @@ RuboCop::Cop::RSpec::NestedGroups::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::NotToNot < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def not_to_not_offense(node = _, param1); end def on_send(node); end @@ -1057,6 +1066,7 @@ class RuboCop::Cop::RSpec::PredicateMatcher < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) include(::RuboCop::Cop::RSpec::InflectedHelper) include(::RuboCop::Cop::RSpec::ExplicitHelper) + extend(::RuboCop::Cop::AutoCorrector) def autocorrect(node); end def on_block(node); end @@ -1069,13 +1079,15 @@ class RuboCop::Cop::RSpec::PredicateMatcher < ::RuboCop::Cop::RSpec::Cop end class RuboCop::Cop::RSpec::ReceiveCounts < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def on_send(node); end def receive_counts(node = _); end def stub?(node0); end private + def autocorrect(corrector, node, range); end def matcher_for(method, count); end def message_for(node, source); end def range(node, offending_node); end @@ -1084,9 +1096,14 @@ end RuboCop::Cop::RSpec::ReceiveCounts::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::ReceiveNever < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def method_on_stub?(node0); end def on_send(node); end + + private + + def autocorrect(corrector, node); end end RuboCop::Cop::RSpec::ReceiveNever::MSG = T.let(T.unsafe(nil), String) @@ -1149,9 +1166,9 @@ RuboCop::Cop::RSpec::RepeatedExampleGroupDescription::MSG = T.let(T.unsafe(nil), class RuboCop::Cop::RSpec::ReturnFromStub < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) def and_return_value(node0); end - def autocorrect(node); end def contains_stub?(node0); end def on_block(node); end def on_send(node); end @@ -1200,7 +1217,8 @@ RuboCop::Cop::RSpec::ReturnFromStub::MSG_AND_RETURN = T.let(T.unsafe(nil), Strin RuboCop::Cop::RSpec::ReturnFromStub::MSG_BLOCK = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::ScatteredLet < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def on_block(node); end private @@ -1220,7 +1238,8 @@ end RuboCop::Cop::RSpec::ScatteredSetup::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::SharedContext < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def context?(node0); end def examples?(node0); end def on_block(node); end @@ -1229,7 +1248,6 @@ class RuboCop::Cop::RSpec::SharedContext < ::RuboCop::Cop::RSpec::Cop private - def add_shared_item_offense(node, message); end def context_with_only_examples(node); end def examples_with_only_context(node); end end @@ -1239,7 +1257,8 @@ RuboCop::Cop::RSpec::SharedContext::MSG_CONTEXT = T.let(T.unsafe(nil), String) RuboCop::Cop::RSpec::SharedContext::MSG_EXAMPLES = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::SharedExamples < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def on_send(node); end def shared_examples(node = _); end end @@ -1260,17 +1279,18 @@ end RuboCop::Cop::RSpec::SharedExamples::Checker::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::SingleArgumentMessageChain < ::RuboCop::Cop::RSpec::Cop - def autocorrect(node); end + extend(::RuboCop::Cop::AutoCorrector) + def message_chain(node = _); end def on_send(node); end def single_key_hash?(node = _); end private + def autocorrect(corrector, node, method, arg); end def autocorrect_array_arg(corrector, arg); end def autocorrect_hash_arg(corrector, arg); end def key_to_arg(node); end - def message(node); end def replacement(method); end def single_element_array?(node); end def valid_usage?(node); end @@ -1360,8 +1380,8 @@ RuboCop::Cop::RSpec::VoidExpect::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::RSpec::Yield < ::RuboCop::Cop::RSpec::Cop include(::RuboCop::Cop::RangeHelp) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def block_arg(node = _); end def block_call?(node = _, param1); end def method_on_stub?(node0); end @@ -1369,6 +1389,7 @@ class RuboCop::Cop::RSpec::Yield < ::RuboCop::Cop::RSpec::Cop private + def autocorrect(corrector, node, range); end def block_range(node); end def calling_block?(node, block); end def convert_block_to_yield(node); end @@ -1407,7 +1428,6 @@ module RuboCop::RSpec::BlankLineSeparation include(::RuboCop::RSpec::FinalEndLocation) include(::RuboCop::Cop::RangeHelp) - def autocorrect(node); end def last_child?(node); end def missing_separating_line(node); end def offending_loc(last_line); end diff --git a/Library/Homebrew/sorbet/rbi/gems/rubocop@0.87.0.rbi b/Library/Homebrew/sorbet/rbi/gems/rubocop@0.88.0.rbi similarity index 98% rename from Library/Homebrew/sorbet/rbi/gems/rubocop@0.87.0.rbi rename to Library/Homebrew/sorbet/rbi/gems/rubocop@0.88.0.rbi index 67e0482a29..defd5528c7 100644 --- a/Library/Homebrew/sorbet/rbi/gems/rubocop@0.87.0.rbi +++ b/Library/Homebrew/sorbet/rbi/gems/rubocop@0.88.0.rbi @@ -289,6 +289,8 @@ class RuboCop::ConfigLoader def self.merge(base_hash, derived_hash); end def self.merge_with_default(config, config_file, unset_nil: _); end def self.possible_new_cops?(config); end + def self.project_root; end + def self.project_root=(_); end def self.warn_on_pending_cops(pending_cops); end end @@ -363,6 +365,7 @@ class RuboCop::ConfigStore def for(file_or_dir); end def for_dir(dir); end def for_file(file); end + def for_pwd; end def force_default_config!; end def options_config=(options_config); end end @@ -549,6 +552,8 @@ class RuboCop::Cop::Base def complete_investigation; end def correct(range); end def correction_strategy; end + def current_offense_locations; end + def currently_disabled_lines; end def custom_severity; end def default_severity; end def disable_uncorrectable(range); end @@ -749,6 +754,7 @@ class RuboCop::Cop::Commissioner def on_ensure(node); end def on_erange(node); end def on_false(node); end + def on_find_pattern(node); end def on_float(node); end def on_for(node); end def on_forward_arg(node); end @@ -1602,9 +1608,10 @@ end RuboCop::Cop::Layout::CaseIndentation::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::Layout::ClassStructure < ::RuboCop::Cop::Cop + include(::RuboCop::Cop::VisibilityHelp) + def autocorrect(node); end def on_class(class_node); end - def visibility_block?(node = _); end private @@ -1616,14 +1623,8 @@ class RuboCop::Cop::Layout::ClassStructure < ::RuboCop::Cop::Cop def end_position_for(node); end def expected_order; end def find_category(node); end - def find_visibility_end(node); end - def find_visibility_start(node); end def humanize_node(node); end def ignore?(classification); end - def left_siblings_of(node); end - def node_visibility(node); end - def right_siblings_of(node); end - def siblings_of(node); end def source_range_with_comment(node); end def start_line_position(node); end def walk_over_nested_class_definition(class_node); end @@ -1633,8 +1634,6 @@ RuboCop::Cop::Layout::ClassStructure::HUMANIZED_NODE_TYPE = T.let(T.unsafe(nil), RuboCop::Cop::Layout::ClassStructure::MSG = T.let(T.unsafe(nil), String) -RuboCop::Cop::Layout::ClassStructure::VISIBILITY_SCOPES = T.let(T.unsafe(nil), Array) - class RuboCop::Cop::Layout::ClosingHeredocIndentation < ::RuboCop::Cop::Cop include(::RuboCop::Cop::Heredoc) @@ -2625,8 +2624,10 @@ class RuboCop::Cop::Layout::MultilineBlockLayout < ::RuboCop::Cop::Cop def autocorrect_arguments(corrector, node); end def autocorrect_body(corrector, node, block_body); end def block_arg_string(node, args); end + def characters_needed_for_space_and_pipes(node); end def include_trailing_comma?(args); end def line_break_necessary_in_args?(node); end + def needed_length_for_args(node); end end RuboCop::Cop::Layout::MultilineBlockLayout::ARG_MSG = T.let(T.unsafe(nil), String) @@ -2964,30 +2965,26 @@ RuboCop::Cop::Layout::SpaceAroundKeyword::NAMESPACE_OPERATOR = T.let(T.unsafe(ni RuboCop::Cop::Layout::SpaceAroundKeyword::SAFE_NAVIGATION = T.let(T.unsafe(nil), String) -class RuboCop::Cop::Layout::SpaceAroundMethodCallOperator < ::RuboCop::Cop::Cop +class RuboCop::Cop::Layout::SpaceAroundMethodCallOperator < ::RuboCop::Cop::Base include(::RuboCop::Cop::RangeHelp) - include(::RuboCop::Cop::SurroundingSpace) + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def on_const(node); end def on_csend(node); end def on_send(node); end private - def check_and_add_offense(node, add_left_offense = _); end - def dot_or_safe_navigation_operator?(node); end - def left_token_for_auto_correction(node, operator); end - def next_token(current_token); end - def operator_token(node); end - def previous_token(current_token); end - def right_token_for_auto_correction(operator); end - def valid_left_token?(left, operator); end - def valid_right_token?(right, operator); end + def check_space(begin_pos, end_pos); end + def check_space_after_dot(node); end + def check_space_after_double_colon(node); end + def check_space_before_dot(node); end end RuboCop::Cop::Layout::SpaceAroundMethodCallOperator::MSG = T.let(T.unsafe(nil), String) +RuboCop::Cop::Layout::SpaceAroundMethodCallOperator::SPACES_REGEXP = T.let(T.unsafe(nil), Regexp) + class RuboCop::Cop::Layout::SpaceAroundOperators < ::RuboCop::Cop::Cop include(::RuboCop::Cop::PrecedingFollowingAlignment) include(::RuboCop::Cop::RangeHelp) @@ -3570,7 +3567,9 @@ end RuboCop::Cop::Lint::DeprecatedOpenSSLConstant::MSG = T.let(T.unsafe(nil), String) -class RuboCop::Cop::Lint::DisjunctiveAssignmentInConstructor < ::RuboCop::Cop::Cop +class RuboCop::Cop::Lint::DisjunctiveAssignmentInConstructor < ::RuboCop::Cop::Base + extend(::RuboCop::Cop::AutoCorrector) + def on_def(node); end private @@ -3593,6 +3592,12 @@ end RuboCop::Cop::Lint::DuplicateCaseCondition::MSG = T.let(T.unsafe(nil), String) +class RuboCop::Cop::Lint::DuplicateElsifCondition < ::RuboCop::Cop::Base + def on_if(node); end +end + +RuboCop::Cop::Lint::DuplicateElsifCondition::MSG = T.let(T.unsafe(nil), String) + class RuboCop::Cop::Lint::DuplicateHashKey < ::RuboCop::Cop::Cop include(::RuboCop::Cop::Duplication) @@ -3852,6 +3857,8 @@ end RuboCop::Cop::Lint::InterpolationCheck::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::Lint::LiteralAsCondition < ::RuboCop::Cop::Cop + include(::RuboCop::Cop::RangeHelp) + def message(node); end def on_case(case_node); end def on_if(node); end @@ -3870,6 +3877,7 @@ class RuboCop::Cop::Lint::LiteralAsCondition < ::RuboCop::Cop::Cop def condition(node); end def handle_node(node); end def primitive_array?(node); end + def when_conditions_range(when_node); end end RuboCop::Cop::Lint::LiteralAsCondition::MSG = T.let(T.unsafe(nil), String) @@ -3950,7 +3958,6 @@ class RuboCop::Cop::Lint::NestedMethodDefinition < ::RuboCop::Cop::Cop private - def find_nested_defs(node, &block); end def scoping_method_call?(child); end end @@ -3988,14 +3995,21 @@ RuboCop::Cop::Lint::NextWithoutAccumulator::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::Lint::NonDeterministicRequireOrder < ::RuboCop::Cop::Cop def autocorrect(node); end def loop_variable(node = _); end + def method_require?(node = _); end def on_block(node); end + def on_block_pass(node); end def unsorted_dir_block?(node = _); end def unsorted_dir_each?(node = _); end + def unsorted_dir_each_pass?(node = _); end + def unsorted_dir_glob_pass?(node = _); end def var_is_required?(node0, param1); end private + def correct_block_pass(node); end + def last_arg_range(node); end def unsorted_dir_loop?(node); end + def unsorted_dir_pass?(node); end end RuboCop::Cop::Lint::NonDeterministicRequireOrder::MSG = T.let(T.unsafe(nil), String) @@ -5087,12 +5101,15 @@ class RuboCop::Cop::MultilineLiteralBraceCorrector private + def content_if_comment_present(corrector, node); end def correct_next_line_brace(corrector); end def correct_same_line_brace(corrector); end def last_element_range_with_trailing_comma(node); end def last_element_trailing_comma_range(node); end def node; end def processed_source; end + def remove_trailing_content_of_comment(corrector, range); end + def select_content_to_be_inserted_after_last_element(corrector, node); end end module RuboCop::Cop::MultilineLiteralBraceLayout @@ -5873,10 +5890,12 @@ RuboCop::Cop::Style::AccessModifierDeclarations::INLINE_STYLE_MESSAGE = T.let(T. class RuboCop::Cop::Style::AccessorGrouping < ::RuboCop::Cop::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) + include(::RuboCop::Cop::VisibilityHelp) def autocorrect(node); end def on_class(node); end def on_module(node); end + def on_sclass(node); end private @@ -5887,6 +5906,7 @@ class RuboCop::Cop::Style::AccessorGrouping < ::RuboCop::Cop::Cop def group_accessors(node, accessors); end def grouped_style?; end def message(send_node); end + def previous_line_comment?(node); end def separate_accessors(node); end def separated_style?; end def sibling_accessors(send_node); end @@ -5964,6 +5984,19 @@ module RuboCop::Cop::Style::AnnotationComment def split_comment(comment); end end +class RuboCop::Cop::Style::ArrayCoercion < ::RuboCop::Cop::Base + extend(::RuboCop::Cop::AutoCorrector) + + def array_splat?(node = _); end + def on_array(node); end + def on_if(node); end + def unless_array?(node = _); end +end + +RuboCop::Cop::Style::ArrayCoercion::CHECK_MSG = T.let(T.unsafe(nil), String) + +RuboCop::Cop::Style::ArrayCoercion::SPLAT_MSG = T.let(T.unsafe(nil), String) + class RuboCop::Cop::Style::ArrayJoin < ::RuboCop::Cop::Cop def autocorrect(node); end def join_candidate?(node = _); end @@ -6038,19 +6071,25 @@ end RuboCop::Cop::Style::BeginBlock::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::Style::BisectedAttrAccessor < ::RuboCop::Cop::Cop + include(::RuboCop::Cop::VisibilityHelp) + def autocorrect(node); end def on_class(class_node); end def on_module(class_node); end + def on_sclass(class_node); end private - def accessor_macroses(class_node); end - def accessor_names(class_node); end + def accessor_macroses(class_node, visibility); end + def accessor_names(class_node, visibility); end def attr_reader?(send_node); end + def attr_reader_replacement(macro, node, rest_args); end + def attr_within_visibility_scope?(node, visibility); end def attr_writer?(send_node); end def check(macro, reader_names, writer_names); end def indent(node); end def replacement(macro, node); end + def rest_args(args, reader_names, writer_names); end end RuboCop::Cop::Style::BisectedAttrAccessor::MSG = T.let(T.unsafe(nil), String) @@ -6136,6 +6175,31 @@ end RuboCop::Cop::Style::CaseEquality::MSG = T.let(T.unsafe(nil), String) +class RuboCop::Cop::Style::CaseLikeIf < ::RuboCop::Cop::Cop + include(::RuboCop::Cop::RangeHelp) + + def autocorrect(node); end + def on_if(node); end + + private + + def branch_conditions(node); end + def collect_conditions(node, target, conditions); end + def condition_from_binary_op(lhs, rhs, target); end + def condition_from_send_node(node, target); end + def const_reference?(node); end + def correction_range(node); end + def deparenthesize(node); end + def find_target(node); end + def find_target_in_equality_node(node); end + def find_target_in_match_node(node); end + def find_target_in_send_node(node); end + def indent(node); end + def should_check?(node); end +end + +RuboCop::Cop::Style::CaseLikeIf::MSG = T.let(T.unsafe(nil), String) + class RuboCop::Cop::Style::CharacterLiteral < ::RuboCop::Cop::Cop include(::RuboCop::Cop::StringHelp) @@ -6303,8 +6367,12 @@ end RuboCop::Cop::Style::CommentedKeyword::ALLOWED_COMMENTS = T.let(T.unsafe(nil), Array) +RuboCop::Cop::Style::CommentedKeyword::ALLOWED_COMMENT_REGEXES = T.let(T.unsafe(nil), Array) + RuboCop::Cop::Style::CommentedKeyword::KEYWORDS = T.let(T.unsafe(nil), Array) +RuboCop::Cop::Style::CommentedKeyword::KEYWORD_REGEXES = T.let(T.unsafe(nil), Array) + RuboCop::Cop::Style::CommentedKeyword::MSG = T.let(T.unsafe(nil), String) class RuboCop::Cop::Style::ConditionalAssignment < ::RuboCop::Cop::Cop @@ -6791,6 +6859,8 @@ class RuboCop::Cop::Style::ExponentialNotation < ::RuboCop::Cop::Cop def scientific?(node); end end +RuboCop::Cop::Style::ExponentialNotation::MESSAGES = T.let(T.unsafe(nil), Hash) + class RuboCop::Cop::Style::FloatDivision < ::RuboCop::Cop::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) @@ -6806,6 +6876,8 @@ class RuboCop::Cop::Style::FloatDivision < ::RuboCop::Cop::Cop def offense_condition?(node); end end +RuboCop::Cop::Style::FloatDivision::MESSAGES = T.let(T.unsafe(nil), Hash) + class RuboCop::Cop::Style::For < ::RuboCop::Cop::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) include(::RuboCop::Cop::RangeHelp) @@ -6930,6 +7002,19 @@ end RuboCop::Cop::Style::GuardClause::MSG = T.let(T.unsafe(nil), String) +class RuboCop::Cop::Style::HashAsLastArrayItem < ::RuboCop::Cop::Base + include(::RuboCop::Cop::ConfigurableEnforcedStyle) + extend(::RuboCop::Cop::AutoCorrector) + + def on_hash(node); end + + private + + def braces_style?; end + def check_braces(node); end + def check_no_braces(node); end +end + class RuboCop::Cop::Style::HashEachMethods < ::RuboCop::Cop::Cop include(::RuboCop::Cop::Lint::UnusedArgument) @@ -6950,6 +7035,18 @@ end RuboCop::Cop::Style::HashEachMethods::MSG = T.let(T.unsafe(nil), String) +class RuboCop::Cop::Style::HashLikeCase < ::RuboCop::Cop::Base + def hash_like_case?(node = _); end + def on_case(node); end + + private + + def min_branches_count; end + def nodes_of_same_type?(nodes); end +end + +RuboCop::Cop::Style::HashLikeCase::MSG = T.let(T.unsafe(nil), String) + class RuboCop::Cop::Style::HashSyntax < ::RuboCop::Cop::Cop include(::RuboCop::Cop::ConfigurableEnforcedStyle) include(::RuboCop::Cop::RangeHelp) @@ -7055,12 +7152,12 @@ class RuboCop::Cop::Style::IfUnlessModifier < ::RuboCop::Cop::Cop private def another_statement_on_same_line?(node); end - def eligible_node?(node); end def first_line_comment(node); end def ignored_patterns; end def line_length_enabled_at_line?(line); end def named_capture_in_condition?(node); end - def non_eligible_if?(node); end + def non_eligible_node?(node); end + def non_simple_if_unless?(node); end def parenthesize?(node); end def to_modifier_form(node); end def to_normal_form(node); end @@ -7071,8 +7168,6 @@ class RuboCop::Cop::Style::IfUnlessModifier < ::RuboCop::Cop::Cop def too_long_single_line?(node); end end -RuboCop::Cop::Style::IfUnlessModifier::ASSIGNMENT_TYPES = T.let(T.unsafe(nil), Array) - RuboCop::Cop::Style::IfUnlessModifier::MSG_USE_MODIFIER = T.let(T.unsafe(nil), String) RuboCop::Cop::Style::IfUnlessModifier::MSG_USE_NORMAL = T.let(T.unsafe(nil), String) @@ -8310,6 +8405,14 @@ end RuboCop::Cop::Style::RedundantFetchBlock::MSG = T.let(T.unsafe(nil), String) +class RuboCop::Cop::Style::RedundantFileExtensionInRequire < ::RuboCop::Cop::Cop + def autocorrect(node); end + def on_send(node); end + def require_call?(node = _); end +end + +RuboCop::Cop::Style::RedundantFileExtensionInRequire::MSG = T.let(T.unsafe(nil), String) + class RuboCop::Cop::Style::RedundantFreeze < ::RuboCop::Cop::Cop include(::RuboCop::Cop::FrozenStringLiteral) @@ -9147,19 +9250,14 @@ class RuboCop::Cop::Style::TrailingCommaInHashLiteral < ::RuboCop::Cop::Cop def on_hash(node); end end -class RuboCop::Cop::Style::TrailingMethodEndStatement < ::RuboCop::Cop::Cop - include(::RuboCop::Cop::Alignment) +class RuboCop::Cop::Style::TrailingMethodEndStatement < ::RuboCop::Cop::Base + extend(::RuboCop::Cop::AutoCorrector) - def autocorrect(node); end def on_def(node); end private def body_and_end_on_same_line?(node); end - def break_line_before_end(node, corrector); end - def end_token(node); end - def remove_semicolon(node, corrector); end - def token_before_end(node); end def trailing_end?(node); end end @@ -9978,6 +10076,23 @@ end RuboCop::Cop::VariableForce::ZERO_ARITY_SUPER_TYPE = T.let(T.unsafe(nil), Symbol) +module RuboCop::Cop::VisibilityHelp + extend(::RuboCop::AST::NodePattern::Macros) + + def visibility_block?(node = _); end + + private + + def find_visibility_end(node); end + def find_visibility_start(node); end + def left_siblings_of(node); end + def node_visibility(node); end + def right_siblings_of(node); end + def siblings_of(node); end +end + +RuboCop::Cop::VisibilityHelp::VISIBILITY_SCOPES = T.let(T.unsafe(nil), Array) + class RuboCop::Error < ::StandardError end @@ -10000,15 +10115,15 @@ module RuboCop::Ext::ProcessedSource end module RuboCop::FileFinder - def find_file_upwards(filename, start_dir); end - def find_files_upwards(filename, start_dir); end + def find_file_upwards(filename, start_dir, stop_dir = _); end + def find_last_file_upwards(filename, start_dir, stop_dir = _); end private - def traverse_files_upwards(filename, start_dir); end + def traverse_files_upwards(filename, start_dir, stop_dir); end def self.root_level=(level); end - def self.root_level?(path); end + def self.root_level?(path, stop_dir); end end module RuboCop::Formatter @@ -10488,13 +10603,10 @@ module RuboCop::PathUtil def smart_path(path); end def self.absolute?(path); end - def self.chdir(dir, &block); end def self.hidden_dir?(path); end def self.hidden_file_in_not_hidden_dir?(pattern, path); end def self.match_path?(pattern, path); end - def self.pwd; end def self.relative_path(path, base_dir = _); end - def self.reset_pwd; end def self.smart_path(path); end end @@ -10569,7 +10681,7 @@ class RuboCop::Runner def check_for_infinite_loop(processed_source, offenses); end def check_for_redundant_disables?(source); end def considered_failure?(offense); end - def do_inspection_loop(file, processed_source); end + def do_inspection_loop(file); end def each_inspected_file(files); end def file_finished(file, offenses); end def file_offense_cache(file); end diff --git a/Library/Homebrew/sorbet/rbi/gems/i18n@1.8.3.rbi b/Library/Homebrew/sorbet/rbi/gems/zeitwerk@2.4.0.rbi similarity index 73% rename from Library/Homebrew/sorbet/rbi/gems/i18n@1.8.3.rbi rename to Library/Homebrew/sorbet/rbi/gems/zeitwerk@2.4.0.rbi index 27b1fb4bc6..198c6b42fc 100644 --- a/Library/Homebrew/sorbet/rbi/gems/i18n@1.8.3.rbi +++ b/Library/Homebrew/sorbet/rbi/gems/zeitwerk@2.4.0.rbi @@ -1,5 +1,5 @@ # This file is autogenerated. Do not edit it by hand. Regenerate it with: -# tapioca sync +# tapioca sync --exclude json # typed: true From ab4e956390aceacb96b40a78b49458b9617e2ade Mon Sep 17 00:00:00 2001 From: vidusheeamoli Date: Tue, 21 Jul 2020 23:50:24 +0530 Subject: [PATCH 3/3] sorbet: update hidden definitions --- .../sorbet/rbi/hidden-definitions/hidden.rbi | 350 +++++++++--------- 1 file changed, 173 insertions(+), 177 deletions(-) diff --git a/Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi b/Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi index ccb3e8a6ba..644e2b74c5 100644 --- a/Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi +++ b/Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi @@ -5621,6 +5621,10 @@ class Cask::Cmd::List def full_name?(); end + def json=(value); end + + def json?(); end + def one=(value); end def one?(); end @@ -6243,6 +6247,48 @@ module CodeRay def self.scanner(lang, options=T.unsafe(nil), &block); end end +module Colorize +end + +module Colorize::ClassMethods + def color_codes(); end + + def color_matrix(_=T.unsafe(nil)); end + + def color_methods(); end + + def color_samples(); end + + def colors(); end + + def disable_colorization(value=T.unsafe(nil)); end + + def disable_colorization=(value); end + + def mode_codes(); end + + def modes(); end + + def modes_methods(); end +end + +module Colorize::ClassMethods +end + +module Colorize::InstanceMethods + def colorize(params); end + + def colorized?(); end + + def uncolorize(); end +end + +module Colorize::InstanceMethods +end + +module Colorize +end + class CompilerSelector::Compiler def self.[](*_); end @@ -7969,6 +8015,8 @@ module Homebrew::EnvConfig def self.fail_log_lines(); end + def self.forbidden_licenses(); end + def self.force_brewed_curl?(); end def self.force_brewed_git?(); end @@ -12951,6 +12999,8 @@ end class Net::HTTPAlreadyReported end +Net::HTTPClientError::EXCEPTION_TYPE = Net::HTTPServerException + Net::HTTPClientErrorCode = Net::HTTPClientError Net::HTTPClientException = Net::HTTPServerException @@ -13021,6 +13071,8 @@ end class Net::HTTPRangeNotSatisfiable end +Net::HTTPRedirection::EXCEPTION_TYPE = Net::HTTPRetriableError + Net::HTTPRedirectionCode = Net::HTTPRedirection class Net::HTTPRequestTimeout @@ -13036,6 +13088,8 @@ Net::HTTPResponceReceiver = Net::HTTPResponse Net::HTTPRetriableCode = Net::HTTPRedirection +Net::HTTPServerError::EXCEPTION_TYPE = Net::HTTPFatalError + Net::HTTPServerErrorCode = Net::HTTPServerError Net::HTTPSession = Net::HTTP @@ -19415,6 +19469,10 @@ class RuboCop::Cop::FormulaAudit::Miscellaneous def languageNodeModule?(node0); end end +class RuboCop::Cop::FormulaAudit::OptionDeclarations + def depends_on_build_with(node0); end +end + class RuboCop::Cop::FormulaAudit::Patches def patch_data?(node0); end end @@ -19423,6 +19481,16 @@ class RuboCop::Cop::FormulaAudit::Test def test_calls(node0); end end +class RuboCop::Cop::FormulaAudit::Text + def prefix_path(node0); end +end + +class RuboCop::Cop::FormulaAuditStrict::Text + def interpolated_share_path_starts_with(node0, param1); end + + def share_path_starts_with(node0, param1); end +end + class RuboCop::Cop::FormulaCop def dependency_name_hash_match?(node0, param1); end @@ -19446,11 +19514,20 @@ module RuboCop::RSpec::ExpectOffense end class RuboCop::RSpec::ExpectOffense::AnnotatedSource + def ==(other); end + + def annotations(); end + def initialize(lines, annotations); end + def lines(); end + + def match_annotations?(other); end + def plain_source(); end def with_offense_annotations(offenses); end + ABBREV = ::T.let(nil, ::T.untyped) ANNOTATION_PATTERN = ::T.let(nil, ::T.untyped) end @@ -20756,13 +20833,25 @@ end class SimpleCov::Formatter::Codecov def build_params(ci); end + def create_report(report); end + def detect_ci(); end def display_header(); end - def format(result); end + def format(result, disable_net_blockers=T.unsafe(nil)); end - def upload_to_codecov(req, https); end + def gzip_report(report); end + + def handle_report_response(report); end + + def retry_request(req, https); end + + def upload_to_codecov(ci, report); end + + def upload_to_v2(url, report, query, query_without_token); end + + def upload_to_v4(url, report, query, query_without_token); end APPVEYOR = ::T.let(nil, ::T.untyped) AZUREPIPELINES = ::T.let(nil, ::T.untyped) BITBUCKET = ::T.let(nil, ::T.untyped) @@ -21389,11 +21478,20 @@ module Stdenv end class String + include ::Colorize::InstanceMethods include ::String::Compat def acts_like_string?(); end def at(position); end + def black(); end + + def blink(); end + + def blue(); end + + def bold(); end + def camelcase(first_letter=T.unsafe(nil)); end def camelize(first_letter=T.unsafe(nil)); end @@ -21402,6 +21500,8 @@ class String def constantize(); end + def cyan(); end + def dasherize(); end def deconstantize(); end @@ -21418,6 +21518,10 @@ class String def from(position); end + def green(); end + + def hide(); end + def html_safe(); end def humanize(capitalize: T.unsafe(nil), keep_id_suffix: T.unsafe(nil)); end @@ -21432,16 +21536,70 @@ class String def isutf8(); end + def italic(); end + def kconv(to_enc, from_enc=T.unsafe(nil)); end def last(limit=T.unsafe(nil)); end + def light_black(); end + + def light_blue(); end + + def light_cyan(); end + + def light_green(); end + + def light_magenta(); end + + def light_red(); end + + def light_white(); end + + def light_yellow(); end + + def magenta(); end + def mb_chars(); end + def on_black(); end + + def on_blue(); end + + def on_cyan(); end + + def on_green(); end + + def on_light_black(); end + + def on_light_blue(); end + + def on_light_cyan(); end + + def on_light_green(); end + + def on_light_magenta(); end + + def on_light_red(); end + + def on_light_white(); end + + def on_light_yellow(); end + + def on_magenta(); end + + def on_red(); end + + def on_white(); end + + def on_yellow(); end + def parameterize(separator: T.unsafe(nil), preserve_case: T.unsafe(nil), locale: T.unsafe(nil)); end def pluralize(count=T.unsafe(nil), locale=T.unsafe(nil)); end + def red(); end + def remove(*patterns); end def remove!(*patterns); end @@ -21460,6 +21618,8 @@ class String def starts_with?(*_); end + def swap(); end + def tableize(); end def titlecase(keep_id_suffix: T.unsafe(nil)); end @@ -21502,13 +21662,23 @@ class String def truncate_words(words_count, options=T.unsafe(nil)); end + def underline(); end + def underscore(); end def upcase_first(); end + + def white(); end + + def yellow(); end BLANK_RE = ::T.let(nil, ::T.untyped) ENCODED_BLANKS = ::T.let(nil, ::T.untyped) end +class String + extend ::Colorize::ClassMethods +end + class StringScanner def bol?(); end @@ -23158,86 +23328,28 @@ module URI end class URL - def =~(reg); end - - def [](*args, &block); end - - def []=(*args, &block); end - - def add_to_path(val); end - def branch(); end def cookies(); end def data(); end - def delete(*args); end - - def domain(); end - - def domain=(domain); end - - def format(); end - - def format=(format); end - - def get(*args); end - - def hash=(hash); end - - def host(); end - - def host_with_port(); end - - def params(); end - - def params=(p); end - def path(*args, &block); end - def path=(str); end - - def port(); end - - def port=(port); end - - def post(*args); end - - def put(*args); end - def referer(); end - def req_handler(); end - - def req_handler=(r); end - def revision(); end def revisions(); end def scheme(*args, &block); end - def scheme=(scheme); end - def specs(); end - def string(); end - - def subdomain(); end - - def subdomain=(s); end - - def subdomains(); end - - def subdomains=(s); end - def tag(); end def to_s(*args, &block); end - def to_uri(); end - def trust_cert(); end def uri(); end @@ -23245,122 +23357,6 @@ class URL def user_agent(); end def using(); end - VERSION = ::T.let(nil, ::T.untyped) -end - -class URL::ASJSONHandler -end - -class URL::ASJSONHandler -end - -class URL::BaseJSONHandler -end - -class URL::BaseJSONHandler -end - -class URL::JSONHandler - def initialize(str); end - - def parse(); end - - def str(); end -end - -class URL::JSONHandler -end - -class URL::Mash - def [](k); end - - def []=(k, v); end -end - -class URL::Mash -end - -class URL::NetHandler -end - -class URL::NetHandler -end - -class URL::ParamsHash - def reverse_merge!(other); end - - def to_s(questionmark=T.unsafe(nil)); end - - def |(other); end -end - -class URL::ParamsHash - def self.from_string(str); end -end - -class URL::RequestHandler - def delete(args=T.unsafe(nil)); end - - def get(args=T.unsafe(nil)); end - - def initialize(url); end - - def post(args=T.unsafe(nil)); end - - def put(args=T.unsafe(nil)); end - - def url(); end -end - -class URL::RequestHandler -end - -class URL::Response - def code(); end - - def connection_refused(); end - - def initialize(str, args=T.unsafe(nil)); end - - def json(); end - - def response(); end - - def success?(); end - - def successful?(); end - - def time(); end - - def url(); end - - def url_obj(); end -end - -class URL::Response -end - -class URL::TyHandler - def head(args=T.unsafe(nil)); end -end - -class URL::TyHandler -end - -class URL::YajlHandler -end - -class URL::YajlHandler -end - -class URL - def self.json_handler(); end - - def self.json_handler=(r); end - - def self.req_handler(); end - - def self.req_handler=(r); end end class UnboundMethod @@ -23496,7 +23492,7 @@ class Zeitwerk::Loader def preloads(); end - def push_dir(path); end + def push_dir(path, namespace: T.unsafe(nil)); end def reload(); end