From 8902075693b52e409174311fce8b2c3072b3cf47 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 28 Dec 2022 06:14:56 +0000 Subject: [PATCH 1/3] build(deps): bump rubocop-performance in /Library/Homebrew Bumps [rubocop-performance](https://github.com/rubocop/rubocop-performance) from 1.15.1 to 1.15.2. - [Release notes](https://github.com/rubocop/rubocop-performance/releases) - [Changelog](https://github.com/rubocop/rubocop-performance/blob/master/CHANGELOG.md) - [Commits](https://github.com/rubocop/rubocop-performance/compare/v1.15.1...v1.15.2) --- updated-dependencies: - dependency-name: rubocop-performance dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- Library/Homebrew/Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/Gemfile.lock b/Library/Homebrew/Gemfile.lock index f13a95eba7..02e2dfae33 100644 --- a/Library/Homebrew/Gemfile.lock +++ b/Library/Homebrew/Gemfile.lock @@ -144,7 +144,7 @@ GEM unicode-display_width (>= 1.4.0, < 3.0) rubocop-ast (1.24.0) parser (>= 3.1.1.0) - rubocop-performance (1.15.1) + rubocop-performance (1.15.2) rubocop (>= 1.7.0, < 2.0) rubocop-ast (>= 0.4.0) rubocop-rails (2.17.4) From 4178247be4bff18fc651709b8337485332b77ff6 Mon Sep 17 00:00:00 2001 From: BrewTestBot <1589480+BrewTestBot@users.noreply.github.com> Date: Wed, 28 Dec 2022 06:18:32 +0000 Subject: [PATCH 2/3] brew vendor-gems: commit updates. --- Library/Homebrew/vendor/bundle/bundler/setup.rb | 2 +- .../config/default.yml | 0 .../config/obsoletion.yml | 0 .../lib/rubocop-performance.rb | 0 .../lib/rubocop/cop/mixin/regexp_metacharacter.rb | 0 .../lib/rubocop/cop/mixin/sort_block.rb | 0 .../rubocop/cop/performance/ancestors_include.rb | 0 .../performance/array_semi_infinite_range_slice.rb | 0 .../big_decimal_with_numeric_argument.rb | 0 .../lib/rubocop/cop/performance/bind_call.rb | 0 .../performance/block_given_with_explicit_block.rb | 0 .../lib/rubocop/cop/performance/caller.rb | 0 .../lib/rubocop/cop/performance/case_when_splat.rb | 0 .../lib/rubocop/cop/performance/casecmp.rb | 0 .../cop/performance/chain_array_allocation.rb | 0 .../cop/performance/collection_literal_in_loop.rb | 0 .../rubocop/cop/performance/compare_with_block.rb | 0 .../cop/performance/concurrent_monotonic_time.rb | 0 .../lib/rubocop/cop/performance/constant_regexp.rb | 0 .../lib/rubocop/cop/performance/count.rb | 0 .../lib/rubocop/cop/performance/delete_prefix.rb | 0 .../lib/rubocop/cop/performance/delete_suffix.rb | 0 .../lib/rubocop/cop/performance/detect.rb | 0 .../cop/performance/double_start_end_with.rb | 0 .../lib/rubocop/cop/performance/end_with.rb | 0 .../lib/rubocop/cop/performance/fixed_size.rb | 0 .../lib/rubocop/cop/performance/flat_map.rb | 0 .../cop/performance/inefficient_hash_search.rb | 0 .../lib/rubocop/cop/performance/io_readlines.rb | 0 .../lib/rubocop/cop/performance/map_compact.rb | 0 .../cop/performance/method_object_as_block.rb | 0 .../lib/rubocop/cop/performance/open_struct.rb | 0 .../lib/rubocop/cop/performance/range_include.rb | 0 .../rubocop/cop/performance/redundant_block_call.rb | 0 .../redundant_equality_comparison_block.rb | 0 .../lib/rubocop/cop/performance/redundant_match.rb | 0 .../lib/rubocop/cop/performance/redundant_merge.rb | 0 .../rubocop/cop/performance/redundant_sort_block.rb | 0 .../performance/redundant_split_regexp_argument.rb | 0 .../cop/performance/redundant_string_chars.rb | 10 +++++++--- .../lib/rubocop/cop/performance/regexp_match.rb | 4 ++-- .../lib/rubocop/cop/performance/reverse_each.rb | 0 .../lib/rubocop/cop/performance/reverse_first.rb | 0 .../lib/rubocop/cop/performance/select_map.rb | 0 .../lib/rubocop/cop/performance/size.rb | 0 .../lib/rubocop/cop/performance/sort_reverse.rb | 0 .../lib/rubocop/cop/performance/squeeze.rb | 0 .../lib/rubocop/cop/performance/start_with.rb | 0 .../cop/performance/string_identifier_argument.rb | 0 .../lib/rubocop/cop/performance/string_include.rb | 13 ++++++++----- .../rubocop/cop/performance/string_replacement.rb | 0 .../lib/rubocop/cop/performance/sum.rb | 3 +++ .../lib/rubocop/cop/performance/times_map.rb | 0 .../lib/rubocop/cop/performance/unfreeze_string.rb | 0 .../rubocop/cop/performance/uri_default_parser.rb | 0 .../lib/rubocop/cop/performance_cops.rb | 0 .../lib/rubocop/performance.rb | 0 .../lib/rubocop/performance/inject.rb | 0 .../lib/rubocop/performance/version.rb | 2 +- 59 files changed, 22 insertions(+), 12 deletions(-) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/config/default.yml (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/config/obsoletion.yml (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop-performance.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/mixin/regexp_metacharacter.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/mixin/sort_block.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/ancestors_include.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/array_semi_infinite_range_slice.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/big_decimal_with_numeric_argument.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/bind_call.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/block_given_with_explicit_block.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/caller.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/case_when_splat.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/casecmp.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/chain_array_allocation.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/collection_literal_in_loop.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/compare_with_block.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/concurrent_monotonic_time.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/constant_regexp.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/count.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/delete_prefix.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/delete_suffix.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/detect.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/double_start_end_with.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/end_with.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/fixed_size.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/flat_map.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/inefficient_hash_search.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/io_readlines.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/map_compact.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/method_object_as_block.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/open_struct.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/range_include.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/redundant_block_call.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/redundant_equality_comparison_block.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/redundant_match.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/redundant_merge.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/redundant_sort_block.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/redundant_split_regexp_argument.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/redundant_string_chars.rb (91%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/regexp_match.rb (98%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/reverse_each.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/reverse_first.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/select_map.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/size.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/sort_reverse.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/squeeze.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/start_with.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/string_identifier_argument.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/string_include.rb (71%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/string_replacement.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/sum.rb (99%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/times_map.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/unfreeze_string.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance/uri_default_parser.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/cop/performance_cops.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/performance.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/performance/inject.rb (100%) rename Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/{rubocop-performance-1.15.1 => rubocop-performance-1.15.2}/lib/rubocop/performance/version.rb (91%) diff --git a/Library/Homebrew/vendor/bundle/bundler/setup.rb b/Library/Homebrew/vendor/bundle/bundler/setup.rb index 31752045bc..d2f93fe91e 100644 --- a/Library/Homebrew/vendor/bundle/bundler/setup.rb +++ b/Library/Homebrew/vendor/bundle/bundler/setup.rb @@ -105,7 +105,7 @@ $:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version $:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/ruby-progressbar-1.11.0/lib") $:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/unicode-display_width-2.3.0/lib") $:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/rubocop-1.41.1/lib") -$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/rubocop-performance-1.15.1/lib") +$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/rubocop-performance-1.15.2/lib") $:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/rubocop-rails-2.17.4/lib") $:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/rubocop-rspec-2.16.0/lib") $:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/rubocop-sorbet-0.6.11/lib") diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/config/default.yml b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/config/default.yml similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/config/default.yml rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/config/default.yml diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/config/obsoletion.yml b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/config/obsoletion.yml similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/config/obsoletion.yml rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/config/obsoletion.yml diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop-performance.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop-performance.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop-performance.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop-performance.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/mixin/regexp_metacharacter.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/mixin/regexp_metacharacter.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/mixin/regexp_metacharacter.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/mixin/regexp_metacharacter.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/mixin/sort_block.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/mixin/sort_block.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/mixin/sort_block.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/mixin/sort_block.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/ancestors_include.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/ancestors_include.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/ancestors_include.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/ancestors_include.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/array_semi_infinite_range_slice.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/array_semi_infinite_range_slice.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/array_semi_infinite_range_slice.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/array_semi_infinite_range_slice.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/big_decimal_with_numeric_argument.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/big_decimal_with_numeric_argument.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/big_decimal_with_numeric_argument.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/big_decimal_with_numeric_argument.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/bind_call.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/bind_call.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/bind_call.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/bind_call.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/block_given_with_explicit_block.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/block_given_with_explicit_block.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/block_given_with_explicit_block.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/block_given_with_explicit_block.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/caller.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/caller.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/caller.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/caller.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/case_when_splat.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/case_when_splat.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/case_when_splat.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/case_when_splat.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/casecmp.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/casecmp.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/casecmp.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/casecmp.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/chain_array_allocation.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/chain_array_allocation.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/chain_array_allocation.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/chain_array_allocation.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/collection_literal_in_loop.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/collection_literal_in_loop.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/collection_literal_in_loop.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/collection_literal_in_loop.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/compare_with_block.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/compare_with_block.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/compare_with_block.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/compare_with_block.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/concurrent_monotonic_time.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/concurrent_monotonic_time.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/concurrent_monotonic_time.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/concurrent_monotonic_time.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/constant_regexp.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/constant_regexp.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/constant_regexp.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/constant_regexp.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/count.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/count.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/count.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/count.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/delete_prefix.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/delete_prefix.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/delete_prefix.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/delete_prefix.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/delete_suffix.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/delete_suffix.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/delete_suffix.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/delete_suffix.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/detect.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/detect.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/detect.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/detect.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/double_start_end_with.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/double_start_end_with.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/double_start_end_with.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/double_start_end_with.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/end_with.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/end_with.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/end_with.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/end_with.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/fixed_size.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/fixed_size.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/fixed_size.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/fixed_size.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/flat_map.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/flat_map.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/flat_map.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/flat_map.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/inefficient_hash_search.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/inefficient_hash_search.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/inefficient_hash_search.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/inefficient_hash_search.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/io_readlines.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/io_readlines.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/io_readlines.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/io_readlines.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/map_compact.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/map_compact.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/map_compact.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/map_compact.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/method_object_as_block.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/method_object_as_block.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/method_object_as_block.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/method_object_as_block.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/open_struct.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/open_struct.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/open_struct.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/open_struct.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/range_include.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/range_include.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/range_include.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/range_include.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_block_call.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_block_call.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_block_call.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_block_call.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_equality_comparison_block.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_equality_comparison_block.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_equality_comparison_block.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_equality_comparison_block.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_match.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_match.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_match.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_match.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_merge.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_merge.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_merge.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_merge.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_sort_block.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_sort_block.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_sort_block.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_sort_block.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_split_regexp_argument.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_split_regexp_argument.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_split_regexp_argument.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_split_regexp_argument.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_string_chars.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_string_chars.rb similarity index 91% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_string_chars.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_string_chars.rb index 000d887ced..f6617068ba 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/redundant_string_chars.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/redundant_string_chars.rb @@ -9,6 +9,7 @@ module RuboCop # # bad # str.chars[0..2] # str.chars.slice(0..2) + # str.chars.last # # # good # str[0..2].chars @@ -20,6 +21,7 @@ module RuboCop # # good # str[0] # str[0...2].chars + # str[-1] # # # bad # str.chars.take(2) @@ -33,9 +35,8 @@ module RuboCop # str.size # str.empty? # - # # For example, if the receiver is a blank string, it will be incompatible. + # # For example, if the receiver is an empty string, it will be incompatible. # # If a negative value is specified for the receiver, `nil` is returned. - # str.chars.last # Incompatible with `str[-1]`. # str.chars.last(2) # Incompatible with `str[-2..-1].chars`. # str.chars.drop(2) # Incompatible with `str[2..-1].chars`. # @@ -44,7 +45,7 @@ module RuboCop extend AutoCorrector MSG = 'Use `%s` instead of `%s`.' - RESTRICT_ON_SEND = %i[[] slice first take length size empty?].freeze + RESTRICT_ON_SEND = %i[[] slice first last take length size empty?].freeze def_node_matcher :redundant_chars_call?, <<~PATTERN (send $(send _ :chars) $_ $...) @@ -52,6 +53,7 @@ module RuboCop def on_send(node) return unless (receiver, method, args = redundant_chars_call?(node)) + return if method == :last && !args.empty? range = offense_range(receiver, node) message = build_message(method, args) @@ -86,6 +88,8 @@ module RuboCop "[#{build_call_args(args)}].chars" when :[], :first build_good_method_for_brackets_or_first_method(method, args) + when :last + '[-1]' when :take "[0...#{args.first.source}].chars" else diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/regexp_match.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/regexp_match.rb similarity index 98% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/regexp_match.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/regexp_match.rb index 5a5c5ee62c..43ba6e74fe 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/regexp_match.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/regexp_match.rb @@ -124,8 +124,8 @@ module RuboCop def_node_search :last_matches, <<~PATTERN { - (send (const nil? :Regexp) :last_match) - (send (const nil? :Regexp) :last_match _) + (send (const {nil? cbase} :Regexp) :last_match) + (send (const {nil? cbase} :Regexp) :last_match _) ({back_ref nth_ref} _) (gvar #match_gvar?) } diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/reverse_each.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/reverse_each.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/reverse_each.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/reverse_each.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/reverse_first.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/reverse_first.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/reverse_first.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/reverse_first.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/select_map.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/select_map.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/select_map.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/select_map.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/size.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/size.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/size.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/size.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/sort_reverse.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/sort_reverse.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/sort_reverse.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/sort_reverse.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/squeeze.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/squeeze.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/squeeze.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/squeeze.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/start_with.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/start_with.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/start_with.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/start_with.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/string_identifier_argument.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/string_identifier_argument.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/string_identifier_argument.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/string_identifier_argument.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/string_include.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/string_include.rb similarity index 71% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/string_include.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/string_include.rb index c3d8dcf30a..162708c172 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/string_include.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/string_include.rb @@ -22,11 +22,11 @@ module RuboCop class StringInclude < Base extend AutoCorrector - MSG = 'Use `String#include?` instead of a regex match with literal-only pattern.' - RESTRICT_ON_SEND = %i[match =~ match?].freeze + MSG = 'Use `%sString#include?` instead of a regex match with literal-only pattern.' + RESTRICT_ON_SEND = %i[match =~ !~ match?].freeze def_node_matcher :redundant_regex?, <<~PATTERN - {(send $!nil? {:match :=~ :match?} (regexp (str $#literal?) (regopt))) + {(send $!nil? {:match :=~ :!~ :match?} (regexp (str $#literal?) (regopt))) (send (regexp (str $#literal?) (regopt)) {:match :match?} $str) (match-with-lvasgn (regexp (str $#literal?) (regopt)) $_)} PATTERN @@ -34,11 +34,14 @@ module RuboCop def on_send(node) return unless (receiver, regex_str = redundant_regex?(node)) - add_offense(node) do |corrector| + negation = node.send_type? && node.method?(:!~) + message = format(MSG, negation: ('!' if negation)) + + add_offense(node, message: message) do |corrector| receiver, regex_str = regex_str, receiver if receiver.is_a?(String) regex_str = interpret_string_escapes(regex_str) - new_source = "#{receiver.source}.include?(#{to_string_literal(regex_str)})" + new_source = "#{'!' if negation}#{receiver.source}.include?(#{to_string_literal(regex_str)})" corrector.replace(node.source_range, new_source) end diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/string_replacement.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/string_replacement.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/string_replacement.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/string_replacement.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/sum.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/sum.rb similarity index 99% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/sum.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/sum.rb index 10303a56b9..f81e00b7c4 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/sum.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/sum.rb @@ -70,6 +70,9 @@ module RuboCop class Sum < Base include RangeHelp extend AutoCorrector + extend TargetRubyVersion + + minimum_target_ruby_version 2.4 MSG = 'Use `%s` instead of `%s`.' MSG_IF_NO_INIT_VALUE = diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/times_map.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/times_map.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/times_map.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/times_map.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/unfreeze_string.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/unfreeze_string.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/unfreeze_string.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/unfreeze_string.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/uri_default_parser.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/uri_default_parser.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance/uri_default_parser.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance/uri_default_parser.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance_cops.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance_cops.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/cop/performance_cops.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/cop/performance_cops.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/performance.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/performance.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/performance.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/performance.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/performance/inject.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/performance/inject.rb similarity index 100% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/performance/inject.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/performance/inject.rb diff --git a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/performance/version.rb b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/performance/version.rb similarity index 91% rename from Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/performance/version.rb rename to Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/performance/version.rb index 0f11abe706..693d5510bb 100644 --- a/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.1/lib/rubocop/performance/version.rb +++ b/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/rubocop-performance-1.15.2/lib/rubocop/performance/version.rb @@ -4,7 +4,7 @@ module RuboCop module Performance # This module holds the RuboCop Performance version information. module Version - STRING = '1.15.1' + STRING = '1.15.2' def self.document_version STRING.match('\d+\.\d+').to_s From f55d819f39b06271ad602c0dca97f10447c97ccf Mon Sep 17 00:00:00 2001 From: BrewTestBot <1589480+BrewTestBot@users.noreply.github.com> Date: Wed, 28 Dec 2022 06:26:41 +0000 Subject: [PATCH 3/3] Update RBI files for rubocop-performance. Autogenerated by the [vendor-gems](https://github.com/Homebrew/brew/blob/HEAD/.github/workflows/vendor-gemss.yml) workflow. --- ...cop-performance@1.15.1.rbi => rubocop-performance@1.15.2.rbi} | 1 + Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi | 1 + 2 files changed, 2 insertions(+) rename Library/Homebrew/sorbet/rbi/gems/{rubocop-performance@1.15.1.rbi => rubocop-performance@1.15.2.rbi} (99%) diff --git a/Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.15.1.rbi b/Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.15.2.rbi similarity index 99% rename from Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.15.1.rbi rename to Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.15.2.rbi index b3fcb97fec..05dc2abaad 100644 --- a/Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.15.1.rbi +++ b/Library/Homebrew/sorbet/rbi/gems/rubocop-performance@1.15.2.rbi @@ -807,6 +807,7 @@ RuboCop::Cop::Performance::StringReplacement::TR = T.let(T.unsafe(nil), String) class RuboCop::Cop::Performance::Sum < ::RuboCop::Cop::Base include ::RuboCop::Cop::RangeHelp extend ::RuboCop::Cop::AutoCorrector + extend ::RuboCop::Cop::TargetRubyVersion def acc_plus_elem?(param0 = T.unsafe(nil), param1, param2); end def elem_plus_acc?(param0 = T.unsafe(nil), param1, param2); end diff --git a/Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi b/Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi index 3720e245c0..5b7efd036c 100644 --- a/Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi +++ b/Library/Homebrew/sorbet/rbi/hidden-definitions/hidden.rbi @@ -6774,6 +6774,7 @@ module RuboCop::AST::NodePattern::Sets SET_DEPENDS_ON_USES_FROM_MACOS = ::T.let(nil, ::T.untyped) SET_INCLUDE_WITH_WITHOUT = ::T.let(nil, ::T.untyped) SET_MAC_LINUX = ::T.let(nil, ::T.untyped) + SET_MATCH___MATCH = ::T.let(nil, ::T.untyped) SET_ON_INTEL_ON_ARM = ::T.let(nil, ::T.untyped) SET_OR_NEWER_OR_OLDER = ::T.let(nil, ::T.untyped) SET_PRESENT_ANY_BLANK_EMPTY = ::T.let(nil, ::T.untyped)