Don't change the indent for parentheses-enclosed expressions#1410
Merged
0x6675636b796f75676974687562 merged 5 commits intomasterfrom Jun 29, 2022
Merged
Conversation
### What's done: * From now on, parentheses (`LPAR`/`RPAR`) don't increment or decrement the indent unless they're a part of a function declaration or a function call. * Parentheses which just enclose an expression don't affect the indent at all. * This fixes #1409.
Codecov Report
@@ Coverage Diff @@
## master #1410 +/- ##
============================================
- Coverage 83.39% 83.39% -0.01%
Complexity 2557 2557
============================================
Files 106 106
Lines 7575 7598 +23
Branches 2087 2095 +8
============================================
+ Hits 6317 6336 +19
- Misses 372 373 +1
- Partials 886 889 +3
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
Contributor
Contributor
petertrr
reviewed
Jun 28, 2022
### What's done: * Unit tests added
### What's done: * Unit tests corrected. * `IndentationRule` fixed.
petertrr
approved these changes
Jun 29, 2022
### What's done: * Formatting corrected.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What's done:
LPAR/RPAR) don't increment or decrement theindent unless they're a part of a function declaration or a function call.
WRONG_INDENTATION: false positives for parentheses-surrounded infix expressions #1409.Actions checklist