-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Support linting cuddled else #651
Comments
yup, I'd envision this working as a configuration option on the statement position rule. |
@jpsim I folded the listing for uncuddled else into statement position on my branch, but I closed the PR until I get autocorrect implemented for the alternate style, if you have any comments on the parameter name or implementation let me know |
That looks good to me! Not 100% sure about the wording, but can't think of anything better either. I could imagine autocorrect for the uncuddled case being difficult to get right with indentation, so I'd accept if autocorrect just skipped that rule if the uncuddled mode was specified. |
@jpsim I changed the options to use snake case to match the rest of the options, and have an autocorrect option that's passing tests |
As an alternative to the standard StatementPosition Rule, I'd like to see support for uncuddled else statements, either as a configuration option for statement position, or as a separate mutually exclusive rule.
The text was updated successfully, but these errors were encountered: