Format spaces around in keyword
Fixes: KT-10680
This commit is contained in:
committed by
Nikolay Krasko
parent
8fe63cdfaf
commit
655fc45a87
@@ -167,6 +167,7 @@ fun createSpacingBuilder(settings: CodeStyleSettings, builderUtil: KotlinSpacing
|
|||||||
|
|
||||||
around(AS_KEYWORD).spaces(1)
|
around(AS_KEYWORD).spaces(1)
|
||||||
around(IS_KEYWORD).spaces(1)
|
around(IS_KEYWORD).spaces(1)
|
||||||
|
around(IN_KEYWORD).spaces(1)
|
||||||
aroundInside(IDENTIFIER, BINARY_EXPRESSION).spaces(1)
|
aroundInside(IDENTIFIER, BINARY_EXPRESSION).spaces(1)
|
||||||
|
|
||||||
// before LPAR in constructor(): this() {}
|
// before LPAR in constructor(): this() {}
|
||||||
|
|||||||
Vendored
+5
@@ -0,0 +1,5 @@
|
|||||||
|
fun f() {
|
||||||
|
if (1 in intArrayOf()) {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
Vendored
+5
@@ -0,0 +1,5 @@
|
|||||||
|
fun f() {
|
||||||
|
if (1 in intArrayOf()) {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -349,6 +349,12 @@ public class FormatterTestGenerated extends AbstractFormatterTest {
|
|||||||
doTest(fileName);
|
doTest(fileName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("In.after.kt")
|
||||||
|
public void testIn() throws Exception {
|
||||||
|
String fileName = KotlinTestUtils.navigationMetadata("idea/testData/formatter/In.after.kt");
|
||||||
|
doTest(fileName);
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("InfixCall.after.kt")
|
@TestMetadata("InfixCall.after.kt")
|
||||||
public void testInfixCall() throws Exception {
|
public void testInfixCall() throws Exception {
|
||||||
String fileName = KotlinTestUtils.navigationMetadata("idea/testData/formatter/InfixCall.after.kt");
|
String fileName = KotlinTestUtils.navigationMetadata("idea/testData/formatter/InfixCall.after.kt");
|
||||||
|
|||||||
Reference in New Issue
Block a user