brew vendor-gems: commit updates.

This commit is contained in:
BrewTestBot 2022-06-17 18:06:56 +00:00
parent 8e0a5f14f2
commit a2618f4a65
No known key found for this signature in database
GPG Key ID: 82D7D104050B0F0F
37 changed files with 40 additions and 4 deletions

View File

@ -88,7 +88,7 @@ $:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-1.27.0/lib"
$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-performance-1.14.2/lib"
$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-rails-2.15.0/lib"
$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-rspec-2.11.1/lib"
$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-sorbet-0.6.8/lib"
$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/rubocop-sorbet-0.6.10/lib"
$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/ruby-macho-3.0.0/lib"
$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/simplecov-html-0.12.3/lib"
$:.unshift "#{path}/../#{ruby_engine}/#{ruby_version}/gems/simplecov_json_formatter-0.1.4/lib"

View File

@ -97,6 +97,12 @@ Sorbet/ForbidTUnsafe:
VersionAdded: 0.7.0
VersionChanged: 0.7.0
Sorbet/ForbidTUntyped:
Description: 'Forbid usage of T.untyped'
Enabled: false
VersionAdded: 0.6.9
VersionChanged: 0.7.0
Sorbet/ForbidUntypedStructProps:
Description: >-
Disallows use of `T.untyped` or `T.nilable(T.untyped)` as a

View File

@ -65,7 +65,7 @@ module RuboCop
def_node_matcher(:generic_parameter_decl_block_call?, <<-PATTERN)
(block
(send nil? {:type_template :type_member}) ...
(send nil? {:type_template :type_member} ...) ...
)
PATTERN

View File

@ -0,0 +1,29 @@
# frozen_string_literal: true
require "rubocop"
module RuboCop
module Cop
module Sorbet
# This cop disallows using `T.untyped` anywhere.
#
# @example
#
# # bad
# sig { params(my_argument: T.untyped).void }
# def foo(my_argument); end
#
# # good
# sig { params(my_argument: String).void }
# def foo(my_argument); end
#
class ForbidTUntyped < RuboCop::Cop::Cop
def_node_matcher(:t_untyped?, "(send (const nil? :T) :untyped)")
def on_send(node)
add_offense(node, message: "Do not use `T.untyped`.") if t_untyped?(node)
end
end
end
end
end

View File

@ -49,7 +49,7 @@ module RuboCop
protected
STRICTNESS_LEVELS = ["ignore", "false", "true", "strict", "strong"]
SIGIL_REGEX = /#\s+typed:(?:\s+([\w]+))?/
SIGIL_REGEX = /^\s*#\s+typed:(?:\s+([\w]+))?/
# extraction

View File

@ -7,6 +7,7 @@ require_relative "sorbet/forbid_untyped_struct_props"
require_relative "sorbet/one_ancestor_per_line"
require_relative "sorbet/callback_conditionals_binding"
require_relative "sorbet/forbid_t_unsafe"
require_relative "sorbet/forbid_t_untyped"
require_relative "sorbet/type_alias_name"
require_relative "sorbet/rbi/forbid_extend_t_sig_helpers_in_shims"

View File

@ -1,6 +1,6 @@
# frozen_string_literal: true
module RuboCop
module Sorbet
VERSION = "0.6.8"
VERSION = "0.6.10"
end
end