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
I have a multiline method call where the parameters to the method are on separate lines. I want to exclude the last parameter of this call from simplecov. The way you do that is to surround the line with # :nocov: comments. However, this triggers a false positive for Style/CommentIndentation:
It seems like Style/CommentIndentation is trying to group the second # :nocov: comment with the following line (the closing paren), since the following formatting passes:
method.call(:foo,:bar,# :nocov::baz# :nocov:)
which (I think everyone would agree) looks bad.
Does this generalize? Should Style/CommentIndentation simply adhere to the preceding line's indentation if the following line is a closing paren or something like that? It seems to already do that for hashes & arrays, like:
We already had special handling of comments before closing curly
brace and closing square bracket. Handle a closing round parenthesis
the same way, which is that the comment should be indented one step
more than the following line.
I have a multiline method call where the parameters to the method are on separate lines. I want to exclude the last parameter of this call from simplecov. The way you do that is to surround the line with
# :nocov:
comments. However, this triggers a false positive forStyle/CommentIndentation
:It seems like
Style/CommentIndentation
is trying to group the second# :nocov:
comment with the following line (the closing paren), since the following formatting passes:which (I think everyone would agree) looks bad.
Does this generalize? Should
Style/CommentIndentation
simply adhere to the preceding line's indentation if the following line is a closing paren or something like that? It seems to already do that for hashes & arrays, like:The text was updated successfully, but these errors were encountered: