You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Fix#8871] Fix a false positive for Style/RedundantBegin
Fixes#8871.
This PR fixes a false positive for `Style/RedundantBegin`
when using `begin` for method argument or part of conditions.
`begin` keyword may be redundant when using only one expression
in `begin` of each issue case.
However, since it is the unintended case for #8822, I think it
can be implemented as an enhancement different from this bug fix.
Copy file name to clipboardExpand all lines: CHANGELOG.md
+1
Original file line number
Diff line number
Diff line change
@@ -9,6 +9,7 @@
9
9
*[#8869](https://github.com/rubocop-hq/rubocop/issues/8869): Fix a false positive for `Style/RedundantBegin` when using `begin` for or assignment and method call. ([@koic][])
10
10
*[#8862](https://github.com/rubocop-hq/rubocop/issues/8862): Fix an error for `Lint/AmbiguousRegexpLiteral` when using regexp without method calls in nested structure. ([@koic][])
11
11
*[#8872](https://github.com/rubocop-hq/rubocop/issues/8872): Fix an error for `Metrics/ClassLength` when multiple assignments to constants. ([@koic][])
12
+
*[#8871](https://github.com/rubocop-hq/rubocop/issues/8871): Fix a false positive for `Style/RedundantBegin` when using `begin` for method argument or part of conditions. ([@koic][])
0 commit comments