-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Comparing changes
Open a pull request
base repository: rubocop/rubocop
base: v1.66.0
head repository: rubocop/rubocop
compare: v1.66.1
- 15 commits
- 25 files changed
- 4 contributors
Commits on Aug 31, 2024
-
Configuration menu - View commit details
-
Copy full SHA for e0de443 - Browse repository at this point
Copy the full SHA e0de443View commit details
Commits on Sep 1, 2024
-
Fix crash in
Style/EmptyElse
whenAllowComments: true
and the els……e clause is missing
Configuration menu - View commit details
-
Copy full SHA for 435bed6 - Browse repository at this point
Copy the full SHA 435bed6View commit details -
Merge pull request #13177 from vlad-pisanov/vp_empty_else_1
Fix crash in `Style/EmptyElse` when `AllowComments: true` and the else clause is missing
Configuration menu - View commit details
-
Copy full SHA for 7bb9708 - Browse repository at this point
Copy the full SHA 7bb9708View commit details -
Fix false positive for
Style/EmptyLiteral
withHash.new([])
The first parameter for Hash.new is the default value: ```rb Hash.new([])[:foo] # => [] ``` Side note: this usage is most likely a programming error. You want the block form where different keys _don't_ share the same underlying array.
Configuration menu - View commit details
-
Copy full SHA for 60d3cd6 - Browse repository at this point
Copy the full SHA 60d3cd6View commit details -
Merge pull request #13178 from Earlopain/style-empty-literal-hash-def…
…ault-value Fix false positive for `Style/EmptyLiteral` with `Hash.new([])`
Configuration menu - View commit details
-
Copy full SHA for 4bb7cba - Browse repository at this point
Copy the full SHA 4bb7cbaView commit details -
Configuration menu - View commit details
-
Copy full SHA for fd4f4d7 - Browse repository at this point
Copy the full SHA fd4f4d7View commit details
Commits on Sep 2, 2024
-
Merge pull request #13179 from Earlopain/node-matcher-directiry-error
Fix an error for `InternalAffairs/NodeMatcherDirective` when no second argument
Configuration menu - View commit details
-
Copy full SHA for 9a38b11 - Browse repository at this point
Copy the full SHA 9a38b11View commit details -
Configuration menu - View commit details
-
Copy full SHA for 3277118 - Browse repository at this point
Copy the full SHA 3277118View commit details
Commits on Sep 3, 2024
-
Fix false negatives in
Style/MapIntoArray
autocorrection when using…… `ensure`, `def`, `defs` and `for`
Configuration menu - View commit details
-
Copy full SHA for d18b3c9 - Browse repository at this point
Copy the full SHA d18b3c9View commit details -
Merge pull request #13185 from vlad-pisanov/vp_map_into_array_2
Fix false negatives in `Style/MapIntoArray` autocorrection
Configuration menu - View commit details
-
Copy full SHA for 5e65a39 - Browse repository at this point
Copy the full SHA 5e65a39View commit details -
Use
rubocop-ast
SimpleForwardable
Introduced in rubocop/rubocop-ast#312 Also see #13175 I performance tested this change and found no significant difference, which makes sense since it's basically the same thing
Configuration menu - View commit details
-
Copy full SHA for 5f3481f - Browse repository at this point
Copy the full SHA 5f3481fView commit details
Commits on Sep 4, 2024
-
Once for the duplication check, and once again to convert it to a ruby hash We can instead use the yaml ast from the duplication check and convert that into a hash directly. ``` # Rubocop # Base: $ hyperfine -w 5 -r 20 "bundle exec rubocop Rakefile" Benchmark 1: bundle exec rubocop Rakefile Time (mean ± σ): 1.041 s ± 0.014 s [User: 0.898 s, System: 0.140 s] Range (min … max): 1.013 s … 1.061 s 20 runs # Patch: $ hyperfine -w 5 -r 20 "bundle exec rubocop Rakefile" Benchmark 1: bundle exec rubocop Rakefile Time (mean ± σ): 1.013 s ± 0.008 s [User: 0.865 s, System: 0.146 s] Range (min … max): 0.998 s … 1.027 s 20 runs ``` ~2.7% Faster ``` # Gitlab # Base: $ hyperfine -w 5 -r 20 "bundle exec rubocop Rakefile" Benchmark 1: bundle exec rubocop Rakefile Time (mean ± σ): 3.485 s ± 0.027 s [User: 2.565 s, System: 0.909 s] Range (min … max): 3.445 s … 3.529 s 20 runs # Applied: $ hyperfine -w 5 -r 20 "bundle exec rubocop Rakefile" Benchmark 1: bundle exec rubocop Rakefile Time (mean ± σ): 3.401 s ± 0.029 s [User: 2.483 s, System: 0.906 s] Range (min … max): 3.356 s … 3.466 s 20 runs ``` ~2.5% faster. I expected more since they have so many config files but hey, still something.
Configuration menu - View commit details
-
Copy full SHA for c2ae362 - Browse repository at this point
Copy the full SHA c2ae362View commit details -
Fix an error for
Style/IfWithSemicolon
This PR fixes the following error for `Style/IfWithSemicolon` when when using nested single-line if/;/end in block of if/else branches. ```console $ cat /tmpp/example.rb if foo?;bar;else baz do if qux;else quux;end;end;end $ bundle exec rubocop --only Style/IfWithSemicolon /tmp/example.rb -a -d (snip) An error occurred while Style/IfWithSemicolon cop was inspecting /tmp/example.rb:1:24. Parser::Source::TreeRewriter detected clobbering /Users/koic/.rbenv/versions/3.4-dev/lib/ruby/gems/3.4.0+0/gems/parser-3.3.4.2/lib/parser/source/tree_rewriter.rb:427 :in 'Parser::Source::TreeRewriter#trigger_policy' ```
Configuration menu - View commit details
-
Copy full SHA for 08bed81 - Browse repository at this point
Copy the full SHA 08bed81View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2900c91 - Browse repository at this point
Copy the full SHA 2900c91View commit details -
Configuration menu - View commit details
-
Copy full SHA for ba8e7be - Browse repository at this point
Copy the full SHA ba8e7beView commit details
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff v1.66.0...v1.66.1