-
Notifications
You must be signed in to change notification settings - Fork 39
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
Bugfix. Newline rule rbrace(#617) #650
Conversation
### What's done: * Logic began
### What's done: * Added case for right brace
Codecov Report
@@ Coverage Diff @@
## master #650 +/- ##
=========================================
Coverage 78.91% 78.91%
Complexity 1789 1789
=========================================
Files 88 88
Lines 4696 4696
Branches 1506 1506
=========================================
Hits 3706 3706
Misses 298 298
Partials 692 692
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
### What's done: * Fixed bugs
### What's done: * Fixed bugs
@@ -113,11 +116,58 @@ class NewlinesRule(private val configRules: List<RulesConfig>) : Rule("newlines" | |||
BLOCK -> handleLambdaBody(node) | |||
RETURN -> handleReturnStatement(node) | |||
SUPER_TYPE_LIST, VALUE_PARAMETER_LIST -> handleList(node) | |||
RBRACE -> handleRightBrace(node) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't it be handled in BlockStructureBraces
instead of NewlinesRule
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Completly forgot about it. Remade bugfix
### What's done: * Fixed bugs
@@ -144,6 +143,7 @@ class DiktatRuleSetProvider(private var diktatConfigFile: String = DIKTAT_ANALYS | |||
::AvoidNestedFunctionsRule, | |||
::ExtensionFunctionsSameNameRule, | |||
// formatting: moving blocks, adding line breaks, indentations etc. | |||
::BlockStructureBraces, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wow, that turned out easy..
Handle of right brace case was added
This pull request closes #617