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
Clobbering error from Lint/EmptyConditionalBody
#11132
Comments
@ydah Do you know of any good solutions for this? I ask you because previously you had made changes about this Cop at #11017 and I thought maybe you would be familiar with it. I think it's probably caused by the overlapping range of |
I ran
rubocop
to the following code and encountered an error.Since the above example is the most minimal example, it may seem that it is an edge case that almost never happens in real life. In a real application, this kind of problem would be possible with code like the following:
Expected behavior
Expect that no internal error is raised.
Actual behavior
Steps to reproduce the problem
Create an empty project with the following
Gemfile
:then run
bundle install
and create example.rb like this:then run
bundle exec rubocop
.The another option is to add a test case to rubocop and run it like this:
(Note:
-RUBY
is used instead of~RUBY
for adding indentation)RuboCop version
The text was updated successfully, but these errors were encountered: