-
-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Infinite loop caused by Layout/MultilineMethodDefinitionBraceLayout and Layout/HeredocArgumentClosingParenthesis interaction #8046
Comments
then
@koic what behavior |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contribution and understanding! |
…enthesis` Fixes rubocop#8046. This PR fixes an error for `Layout/HeredocArgumentClosingParenthesis` when existing an argument between heredoc of end and closing parentheses. `Layout/HeredocArgumentClosingParenthesis` alone reproduced an error without being affected by other cops.
Fixes #8046. This PR fixes an error for `Layout/HeredocArgumentClosingParenthesis` when existing an argument between heredoc of end and closing parentheses. `Layout/HeredocArgumentClosingParenthesis` alone reproduced an error without being affected by other cops.
I'm occasionally running into an infinite loop error when I have both
Layout/MultilineMethodDefinitionBraceLayout
andLayout/HeredocArgumentClosingParenthesis
enabled. By "occasionally" I mean that it only happens on some files in our codebase, but it happens consistently on those files.Original code
Expected behavior
Code transformed to:
Actual behavior
An infinite loop error:
Steps to reproduce the problem
Run
rubocop --safe-auto-correct --disable-uncorrectable example.rb
with the Original code snippet in example.rb. Reproducible with the following cop configuration:RuboCop version
The text was updated successfully, but these errors were encountered: