Skip to content

Commit

Permalink
Cut 1.19.1
Browse files Browse the repository at this point in the history
  • Loading branch information
koic committed Sep 17, 2023
1 parent e78d6aa commit 83cadd6
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 7 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Expand Up @@ -11,6 +11,8 @@

## master (unreleased)

## 1.19.1 (2023-09-17)

### Bug fixes

* [#367](https://github.com/rubocop/rubocop-performance/issues/367): Fix an incorrect autocorrect for `Performance/BlockGivenWithExplicitBlock` when using `Lint/UnusedMethodArgument`'s autocorrection together. ([@ymap][])
Expand Down
2 changes: 1 addition & 1 deletion docs/antora.yml
Expand Up @@ -2,6 +2,6 @@ name: rubocop-performance
title: RuboCop Performance
# We always provide version without patch here (e.g. 1.1),
# as patch versions should not appear in the docs.
version: ~
version: '1.19'
nav:
- modules/ROOT/nav.adoc
13 changes: 8 additions & 5 deletions docs/modules/ROOT/pages/cops_performance.adoc
Expand Up @@ -1328,6 +1328,12 @@ is wanted.

This cop is unsafe because `Range#include?` (or `Range#member?`) and `Range#cover?`
are not equivalent behavior.
Example of a case where `Range#cover?` may not provide the desired result:

[source,ruby]
----
('a'..'z').cover?('yellow') # => true
----

=== Examples

Expand All @@ -1339,11 +1345,6 @@ are not equivalent behavior.
# good
('a'..'z').cover?('b') # => true
# Example of a case where `Range#cover?` may not provide
# the desired result:
('a'..'z').cover?('yellow') # => true
----

=== References
Expand Down Expand Up @@ -2299,6 +2300,8 @@ end

== Performance/UnfreezeString

NOTE: Required Ruby version: 2.3

|===
| Enabled by default | Safe | Supports autocorrection | Version Added | Version Changed

Expand Down
2 changes: 1 addition & 1 deletion lib/rubocop/performance/version.rb
Expand Up @@ -4,7 +4,7 @@ module RuboCop
module Performance
# This module holds the RuboCop Performance version information.
module Version
STRING = '1.19.0'
STRING = '1.19.1'

def self.document_version
STRING.match('\d+\.\d+').to_s
Expand Down
10 changes: 10 additions & 0 deletions relnotes/v1.19.1.md
@@ -0,0 +1,10 @@
### Bug fixes

* [#367](https://github.com/rubocop/rubocop-performance/issues/367): Fix an incorrect autocorrect for `Performance/BlockGivenWithExplicitBlock` when using `Lint/UnusedMethodArgument`'s autocorrection together. ([@ymap][])
* [#370](https://github.com/rubocop/rubocop-performance/issues/370): Fix an incorrect autocorrect for `Performance/RedundantMatch` when expressions with lower precedence than `=~` are used as an argument. ([@ymap][])
* [#365](https://github.com/rubocop/rubocop-performance/issues/365): Fix false positives for `Performance/ArraySemiInfiniteRangeSlice` when using `[]` with string literals. ([@koic][])
* [#373](https://github.com/rubocop/rubocop-performance/pull/373): Set target version for `Performance/UnfreezeString`. ([@tagliala][])

[@ymap]: https://github.com/ymap
[@koic]: https://github.com/koic
[@tagliala]: https://github.com/tagliala

0 comments on commit 83cadd6

Please sign in to comment.