diff --git a/compiler/frontend/src/org/jetbrains/kotlin/checkers/DiagnosticDescriptors.kt b/compiler/frontend/src/org/jetbrains/kotlin/checkers/DiagnosticDescriptors.kt index 0a97ba450a8..c878187bfc5 100644 --- a/compiler/frontend/src/org/jetbrains/kotlin/checkers/DiagnosticDescriptors.kt +++ b/compiler/frontend/src/org/jetbrains/kotlin/checkers/DiagnosticDescriptors.kt @@ -5,7 +5,6 @@ package org.jetbrains.kotlin.checkers -import com.google.common.collect.Maps import com.intellij.openapi.util.TextRange import org.jetbrains.kotlin.checkers.diagnostics.AbstractTestDiagnostic import org.jetbrains.kotlin.checkers.diagnostics.PositionalTextDiagnostic @@ -21,7 +20,7 @@ class ActualDiagnosticDescriptor internal constructor(start: Int, end: Int, val val textDiagnosticsMap: MutableMap get() { - val diagnosticMap = Maps.newLinkedHashMap() + val diagnosticMap = mutableMapOf() for (diagnostic in diagnostics) { diagnosticMap[diagnostic] = TextDiagnostic.asTextDiagnostic(diagnostic) } diff --git a/compiler/frontend/src/org/jetbrains/kotlin/checkers/utils/CheckerTestUtil.kt b/compiler/frontend/src/org/jetbrains/kotlin/checkers/utils/CheckerTestUtil.kt index 9952ab5f3a1..971a7f716ca 100644 --- a/compiler/frontend/src/org/jetbrains/kotlin/checkers/utils/CheckerTestUtil.kt +++ b/compiler/frontend/src/org/jetbrains/kotlin/checkers/utils/CheckerTestUtil.kt @@ -549,6 +549,7 @@ object CheckerTestUtil { } if (diagnosticsAsText.size != 0) { + diagnosticsAsText.sort() result.append("") isSkip = false } diff --git a/compiler/testData/diagnostics/tests/Basic.kt b/compiler/testData/diagnostics/tests/Basic.kt index 9f860c46855..3d820e00bb1 100644 --- a/compiler/testData/diagnostics/tests/Basic.kt +++ b/compiler/testData/diagnostics/tests/Basic.kt @@ -10,7 +10,7 @@ fun test() : Int { } class A() { - val x : Int = foo1(xx) + val x : Int = foo1(xx) } fun foo1() {} diff --git a/compiler/testData/diagnostics/tests/BinaryCallsOnNullableValues.kt b/compiler/testData/diagnostics/tests/BinaryCallsOnNullableValues.kt index ca348d66eef..c4142161c76 100644 --- a/compiler/testData/diagnostics/tests/BinaryCallsOnNullableValues.kt +++ b/compiler/testData/diagnostics/tests/BinaryCallsOnNullableValues.kt @@ -23,7 +23,7 @@ fun f(): Unit { x !== 1 x..2 - x in 1..2 + x in 1..2 val y : Boolean? = true false || y diff --git a/compiler/testData/diagnostics/tests/Constructors.kt b/compiler/testData/diagnostics/tests/Constructors.kt index 5a346cb0615..82a73dbb743 100644 --- a/compiler/testData/diagnostics/tests/Constructors.kt +++ b/compiler/testData/diagnostics/tests/Constructors.kt @@ -14,7 +14,7 @@ class WithPC1(a : Int) { } -class Foo() : WithPC0, this() { +class Foo() : WithPC0, this() { } diff --git a/compiler/testData/diagnostics/tests/FunctionReturnTypes.kt b/compiler/testData/diagnostics/tests/FunctionReturnTypes.kt index ba1eae2ef4a..c049c95fb57 100644 --- a/compiler/testData/diagnostics/tests/FunctionReturnTypes.kt +++ b/compiler/testData/diagnostics/tests/FunctionReturnTypes.kt @@ -194,7 +194,7 @@ fun testFunctionLiterals() { val endsWithObjectDeclaration : () -> Int = { var x = 1 x = 333 - object A {} + object A {} } val expectedUnitReturnType1: () -> Unit = { diff --git a/compiler/testData/diagnostics/tests/MultipleBounds.kt b/compiler/testData/diagnostics/tests/MultipleBounds.kt index a6f98bb96d5..94fdcfe0db6 100644 --- a/compiler/testData/diagnostics/tests/MultipleBounds.kt +++ b/compiler/testData/diagnostics/tests/MultipleBounds.kt @@ -48,7 +48,7 @@ class BarFoo> class Buzz where T : Bar<Int>, T : nioho class XFoo> -class Y<T> where T : Foo, T : Bar +class Y<T> where T : Foo, T : Bar fun test2(t : T) where diff --git a/compiler/testData/diagnostics/tests/NumberPrefixAndSuffix.kt b/compiler/testData/diagnostics/tests/NumberPrefixAndSuffix.kt index d4b38cb4974..fa84137c5a2 100644 --- a/compiler/testData/diagnostics/tests/NumberPrefixAndSuffix.kt +++ b/compiler/testData/diagnostics/tests/NumberPrefixAndSuffix.kt @@ -8,31 +8,31 @@ infix fun Any?.ddoo(a: Any) {} operator fun Any?.contains(a: Any): Boolean = true fun test(a: Any) { - 1foo a + 1foo a 1ffoo a 1doo a 1ddoo a - 1contains a + 1contains a 1Lfoo a - 1Loo a + 1Loo a 1LLoo a 0b1foo a 0b1Lfoo a - 0b1Loo a + 0b1Loo a 0b1LLoo a - 0xfoo a - 0xffoo a + 0xfoo a + 0xffoo a 0xfLLoo a - 1.0foo a + 1.0foo a 1.0ffoo a 1.0doo a 1.0ddoo a - .0foo a + .0foo a .0ffoo a .0doo a .0ddoo a @@ -40,10 +40,10 @@ fun test(a: Any) { 1in a 1.0in a 1.0fin a - 1.0din a + 1.0din a .0in a .0fin a - .0din a + .0din a 1is Any 1as Any diff --git a/compiler/testData/diagnostics/tests/ResolveToJava.kt b/compiler/testData/diagnostics/tests/ResolveToJava.kt index da19002d0a3..d3af0fcd7cb 100644 --- a/compiler/testData/diagnostics/tests/ResolveToJava.kt +++ b/compiler/testData/diagnostics/tests/ResolveToJava.kt @@ -21,7 +21,7 @@ fun test(l : java.util val f : java.io.File? = null - Collections.emptyList + Collections.emptyList Collections.emptyList Collections.emptyList() Collections.emptyList() diff --git a/compiler/testData/diagnostics/tests/StringPrefixAndSuffix.kt b/compiler/testData/diagnostics/tests/StringPrefixAndSuffix.kt index 446a02b22d2..129386d1840 100644 --- a/compiler/testData/diagnostics/tests/StringPrefixAndSuffix.kt +++ b/compiler/testData/diagnostics/tests/StringPrefixAndSuffix.kt @@ -35,6 +35,6 @@ fun test(a: Any) { if("s"is Any) {} test("s"as Any) - a foo""1 - a foo""1.0 + a foo""1 + a foo""1.0 } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/SupertypeListChecks.kt b/compiler/testData/diagnostics/tests/SupertypeListChecks.kt index 6d345ca2bb3..f053a3fe69d 100644 --- a/compiler/testData/diagnostics/tests/SupertypeListChecks.kt +++ b/compiler/testData/diagnostics/tests/SupertypeListChecks.kt @@ -34,16 +34,16 @@ interface Test4 : T1 {} interface Test5 : T1, T1 {} -interface Test6 : C1 {} +interface Test6 : C1 {} class CTest1() : OC1() {} class CTest2 : C2 {} -class CTest3 : C2, C3 {} +class CTest3 : C2, C3 {} class CTest4 : T1 {} class CTest5 : T1, T1 {} -class CTest6 : C1 {} \ No newline at end of file +class CTest6 : C1 {} \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/TraitOverrideObjectMethods.kt b/compiler/testData/diagnostics/tests/TraitOverrideObjectMethods.kt index 339fcc5587a..c4d1d299e45 100644 --- a/compiler/testData/diagnostics/tests/TraitOverrideObjectMethods.kt +++ b/compiler/testData/diagnostics/tests/TraitOverrideObjectMethods.kt @@ -1,5 +1,5 @@ // JAVAC_EXPECTED_FILE -interface MyTrait: Object { +interface MyTrait: Object { override fun toString(): String public override fun finalize() public override fun wait() diff --git a/compiler/testData/diagnostics/tests/annotations/AmbigiousAnnotationConstructor.kt b/compiler/testData/diagnostics/tests/annotations/AmbigiousAnnotationConstructor.kt index 944a8b14437..a7261c4c663 100644 --- a/compiler/testData/diagnostics/tests/annotations/AmbigiousAnnotationConstructor.kt +++ b/compiler/testData/diagnostics/tests/annotations/AmbigiousAnnotationConstructor.kt @@ -3,4 +3,4 @@ import java.util.ArrayList @ArrayList(1, 1) fun b() {} @Xoo(x) fun c() {} -@java.lang.Deprecated(x) fun a() {} \ No newline at end of file +@java.lang.Deprecated(x) fun a() {} \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/annotations/AnnotationForFunctionTypeParameter.kt b/compiler/testData/diagnostics/tests/annotations/AnnotationForFunctionTypeParameter.kt index bdf7f9c3805..277ea2bd172 100644 --- a/compiler/testData/diagnostics/tests/annotations/AnnotationForFunctionTypeParameter.kt +++ b/compiler/testData/diagnostics/tests/annotations/AnnotationForFunctionTypeParameter.kt @@ -1,12 +1,12 @@ annotation class A1 annotation class A2(val some: Int = 12) -fun <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> topFun() = 12 +fun <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> topFun() = 12 class SomeClass { - fun <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> method() = 12 + fun <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> method() = 12 fun foo() { - fun <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> innerFun() = 12 + fun <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> innerFun() = 12 } } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/annotations/AnnotationsForPropertyTypeParameter.kt b/compiler/testData/diagnostics/tests/annotations/AnnotationsForPropertyTypeParameter.kt index 8e0b675731c..7b2c24f841e 100644 --- a/compiler/testData/diagnostics/tests/annotations/AnnotationsForPropertyTypeParameter.kt +++ b/compiler/testData/diagnostics/tests/annotations/AnnotationsForPropertyTypeParameter.kt @@ -1,10 +1,10 @@ annotation class A1 annotation class A2(val some: Int = 12) -val <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> T.topProp: Int get() = 12 +val <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> T.topProp: Int get() = 12 class SomeClass { - val <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> T.field: Int get() = 12 + val <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> T.field: Int get() = 12 fun foo() { val <@A1 @A2(3) @A2 @A1(12) @A2("Test") T> localVal = 12 diff --git a/compiler/testData/diagnostics/tests/annotations/annotationParameterMustBeConstant/enumConst_after.kt b/compiler/testData/diagnostics/tests/annotations/annotationParameterMustBeConstant/enumConst_after.kt index 44f7626bf03..15248efb9ed 100644 --- a/compiler/testData/diagnostics/tests/annotations/annotationParameterMustBeConstant/enumConst_after.kt +++ b/compiler/testData/diagnostics/tests/annotations/annotationParameterMustBeConstant/enumConst_after.kt @@ -11,5 +11,5 @@ enum class MyEnum { A } -@AnnE(Test()) +@AnnE(Test()) class Test2 \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/annotations/withUseSiteTarget/fileAnnotationWithoutColon_before.kt b/compiler/testData/diagnostics/tests/annotations/withUseSiteTarget/fileAnnotationWithoutColon_before.kt index 4c5d23f349d..ec643868877 100644 --- a/compiler/testData/diagnostics/tests/annotations/withUseSiteTarget/fileAnnotationWithoutColon_before.kt +++ b/compiler/testData/diagnostics/tests/annotations/withUseSiteTarget/fileAnnotationWithoutColon_before.kt @@ -6,6 +6,6 @@ fun test1(@@file @Suppress("") fun test2() {} -class OnType(x: @file Suppress("") Int) +class OnType(x: @file Suppress("") Int) -fun @file : Suppress("") Int.test3() {} \ No newline at end of file +fun @file : Suppress("") Int.test3() {} \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/callableReference/bound/reservedExpressionSyntax.kt b/compiler/testData/diagnostics/tests/callableReference/bound/reservedExpressionSyntax.kt index a4a3f87a651..ec78e1be7ba 100644 --- a/compiler/testData/diagnostics/tests/callableReference/bound/reservedExpressionSyntax.kt +++ b/compiler/testData/diagnostics/tests/callableReference/bound/reservedExpressionSyntax.kt @@ -23,8 +23,8 @@ class Test { fun List.testCallable4(): () -> Unit = b?::foo fun List.testClassLiteral1() = a::class - fun List.testClassLiteral2() = b?::class - fun List.testClassLiteral3() = b::class + fun List.testClassLiteral2() = b?::class + fun List.testClassLiteral3() = b::class fun List.testUnresolved1() = unresolved::foo fun List.testUnresolved2() = a<unresolved>::foo diff --git a/compiler/testData/diagnostics/tests/checkArguments/SpreadVarargs.kt b/compiler/testData/diagnostics/tests/checkArguments/SpreadVarargs.kt index b70eaf83c0c..81a0968b2ac 100644 --- a/compiler/testData/diagnostics/tests/checkArguments/SpreadVarargs.kt +++ b/compiler/testData/diagnostics/tests/checkArguments/SpreadVarargs.kt @@ -27,7 +27,7 @@ fun main() { join(1, "4", *a, *b, "3") join(a = *a, x = 1) join(a = *b, x = 1) - join(a = a, x = 1) + join(a = a, x = 1) joinG(1, "2") joinG(*1, "2") diff --git a/compiler/testData/diagnostics/tests/checkArguments/kt1897_diagnostic_part.kt b/compiler/testData/diagnostics/tests/checkArguments/kt1897_diagnostic_part.kt index b28554c4250..27d6f606ed0 100644 --- a/compiler/testData/diagnostics/tests/checkArguments/kt1897_diagnostic_part.kt +++ b/compiler/testData/diagnostics/tests/checkArguments/kt1897_diagnostic_part.kt @@ -9,11 +9,11 @@ fun foo(i: Int, s: String) {} fun test() { - bar(xx) + bar(xx) bar { } - foo("", 1, xx) + foo("", 1, xx) foo(r = xx, i = "", s = "") diff --git a/compiler/testData/diagnostics/tests/classObjects/InnerClassAccessThroughClassObject.kt b/compiler/testData/diagnostics/tests/classObjects/InnerClassAccessThroughClassObject.kt index f5a74364b7e..4051a3af6a8 100644 --- a/compiler/testData/diagnostics/tests/classObjects/InnerClassAccessThroughClassObject.kt +++ b/compiler/testData/diagnostics/tests/classObjects/InnerClassAccessThroughClassObject.kt @@ -28,7 +28,7 @@ object O { fun f() { A.c A.hashCode() - A().Nested + A().Nested A.Nested() A().Inner() A.Companion.Nested diff --git a/compiler/testData/diagnostics/tests/collectionLiterals/defaultValuesInAnnotation.kt b/compiler/testData/diagnostics/tests/collectionLiterals/defaultValuesInAnnotation.kt index d41d6948ca7..cb9ce738e78 100644 --- a/compiler/testData/diagnostics/tests/collectionLiterals/defaultValuesInAnnotation.kt +++ b/compiler/testData/diagnostics/tests/collectionLiterals/defaultValuesInAnnotation.kt @@ -9,7 +9,7 @@ annotation class Foo( annotation class Bar( val a: Array = [' '], - val b: Array = ["", ''], + val b: Array = ["", ''], val c: Array = [1] ) diff --git a/compiler/testData/diagnostics/tests/controlFlowAnalysis/deadCode/deadCodeInBinaryExpressions.kt b/compiler/testData/diagnostics/tests/controlFlowAnalysis/deadCode/deadCodeInBinaryExpressions.kt index a1054978e8d..fd9690c68f7 100644 --- a/compiler/testData/diagnostics/tests/controlFlowAnalysis/deadCode/deadCodeInBinaryExpressions.kt +++ b/compiler/testData/diagnostics/tests/controlFlowAnalysis/deadCode/deadCodeInBinaryExpressions.kt @@ -8,7 +8,7 @@ fun testBinary2() { } fun testElvis1() { - todo() ?: "" + todo() ?: "" } fun testElvis2(s: String?) { diff --git a/compiler/testData/diagnostics/tests/controlFlowAnalysis/deadCode/deadCodeInWhileFromBreak.kt b/compiler/testData/diagnostics/tests/controlFlowAnalysis/deadCode/deadCodeInWhileFromBreak.kt index 99e4390cf1b..bb1e29a6d98 100644 --- a/compiler/testData/diagnostics/tests/controlFlowAnalysis/deadCode/deadCodeInWhileFromBreak.kt +++ b/compiler/testData/diagnostics/tests/controlFlowAnalysis/deadCode/deadCodeInWhileFromBreak.kt @@ -50,6 +50,6 @@ fun test(arr: Array) { } while (true) { - break ?: null + break ?: null } } diff --git a/compiler/testData/diagnostics/tests/controlFlowAnalysis/delegatedPropertyEarlyAccess.kt b/compiler/testData/diagnostics/tests/controlFlowAnalysis/delegatedPropertyEarlyAccess.kt index e6f2a79edf0..2d1124a13da 100644 --- a/compiler/testData/diagnostics/tests/controlFlowAnalysis/delegatedPropertyEarlyAccess.kt +++ b/compiler/testData/diagnostics/tests/controlFlowAnalysis/delegatedPropertyEarlyAccess.kt @@ -9,12 +9,12 @@ class CustomDelegate { class Kaboom() { // Here and below we should have errors for simple AND delegated init { - delegated.hashCode() + delegated.hashCode() simple.hashCode() withGetter.hashCode() } - val other = delegated + val other = delegated val another = simple diff --git a/compiler/testData/diagnostics/tests/controlStructures/kt770.kt351.kt735_StatementType.kt b/compiler/testData/diagnostics/tests/controlStructures/kt770.kt351.kt735_StatementType.kt index 16e2d27af95..4c65eddf2f2 100644 --- a/compiler/testData/diagnostics/tests/controlStructures/kt770.kt351.kt735_StatementType.kt +++ b/compiler/testData/diagnostics/tests/controlStructures/kt770.kt351.kt735_StatementType.kt @@ -98,7 +98,7 @@ fun testImplicitCoercion() { 3 -> { z = 34 } - else -> z-- + else -> z-- } var iff = if (true) { @@ -108,7 +108,7 @@ fun testImplicitCoercion() { val h = if (false) 4 else {} bar(if (true) { - 4 + 4 } else { z = 342 diff --git a/compiler/testData/diagnostics/tests/controlStructures/localReturnInsidePropertyAccessor.kt b/compiler/testData/diagnostics/tests/controlStructures/localReturnInsidePropertyAccessor.kt index 31f6a82060d..ce50695c506 100644 --- a/compiler/testData/diagnostics/tests/controlStructures/localReturnInsidePropertyAccessor.kt +++ b/compiler/testData/diagnostics/tests/controlStructures/localReturnInsidePropertyAccessor.kt @@ -10,7 +10,7 @@ fun f() = object : ClassData { fun g() = object : ClassData { init { if (true) { - return 0 + return 0 } } diff --git a/compiler/testData/diagnostics/tests/cyclicHierarchy/withCompanion/withMembers_before.kt b/compiler/testData/diagnostics/tests/cyclicHierarchy/withCompanion/withMembers_before.kt index 846cae59100..ce2d253b5e7 100644 --- a/compiler/testData/diagnostics/tests/cyclicHierarchy/withCompanion/withMembers_before.kt +++ b/compiler/testData/diagnostics/tests/cyclicHierarchy/withCompanion/withMembers_before.kt @@ -8,11 +8,11 @@ object WithFunctionInBase { public class C { // error-scope - val data: Data = Data() + val data: Data = Data() open class Base() { // error-scope - fun foo(): Int = 42 + fun foo(): Int = 42 } companion object : DerivedAbstract() @@ -30,11 +30,11 @@ object WithPropertyInBase { open class Base() { // error-scope - val foo: Int = 42 + val foo: Int = 42 } // error-scope - val data: Data = Data() + val data: Data = Data() companion object : DerivedAbstract() } diff --git a/compiler/testData/diagnostics/tests/dataClasses/dataClassVarargParam.kt b/compiler/testData/diagnostics/tests/dataClasses/dataClassVarargParam.kt index 305fc4bac2e..46bf53f6f40 100644 --- a/compiler/testData/diagnostics/tests/dataClasses/dataClassVarargParam.kt +++ b/compiler/testData/diagnostics/tests/dataClasses/dataClassVarargParam.kt @@ -1,3 +1,3 @@ data class My(val x: Int, vararg val y: String) -data class Your(vararg z: String) \ No newline at end of file +data class Your(vararg z: String) \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ArrayAccess.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ArrayAccess.kt index 429cef9e6e5..40d2733bbdb 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ArrayAccess.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ArrayAccess.kt @@ -4,7 +4,7 @@ fun foo() { val x: Int? = null val a = Array(3, {0}) - if (x != null) bar(a[x]) else bar(a[x]) + if (x != null) bar(a[x]) else bar(a[x]) bar(a[if (x == null) 0 else x]) bar(a[x]) diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/BinaryExpression.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/BinaryExpression.kt index a7e3fc3535d..606bc3be388 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/BinaryExpression.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/BinaryExpression.kt @@ -6,6 +6,6 @@ fun foo() { val x: Int? = null bar(1 + (if (x == null) 0 else x)) - bar(if (x == null) x else x) + bar(if (x == null) x else x) if (x != null) bar(x + x/(x-x*x)) } diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/DeepIf.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/DeepIf.kt index 690adabc345..a2a2b5f470d 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/DeepIf.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/DeepIf.kt @@ -17,14 +17,14 @@ fun foo() { if (x == null) bar(x) else bar(x) bar(bar(x)) } else if (x == null) { - bar(x) + bar(x) if (x != null) { bar(x) if (x == null) bar(x) if (x == null) bar(x) else bar(x) bar(bar(x) + bar(x)) } else if (x == null) { - bar(x) + bar(x) } } diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/DoWhile.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/DoWhile.kt index 672242926e3..01de3666935 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/DoWhile.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/DoWhile.kt @@ -12,5 +12,5 @@ fun foo() { do { bar(y) } while (y != null) - bar(y) + bar(y) } diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/IfThenElse.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/IfThenElse.kt index 466c13ee838..9bf7a1753fe 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/IfThenElse.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/IfThenElse.kt @@ -6,7 +6,7 @@ fun foo() { bar(if (x == null) 0 else x) if (x == null) { - bar(x) + bar(x) return } else { bar(x) diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ObjectExpression.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ObjectExpression.kt index 6b334509680..d06b327315e 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ObjectExpression.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ObjectExpression.kt @@ -7,6 +7,6 @@ fun foo() { val a = object { fun baz() = bar(if (x == null) 0 else x) - fun quux(): Int = if (x == null) x else x + fun quux(): Int = if (x == null) x else x } } diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/Return.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/Return.kt index 4f40d73a77c..29792de3840 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/Return.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/Return.kt @@ -9,10 +9,10 @@ fun foo(): Int { if (x != null) return x val y: Int? = null - if (y == null) return if (y != null) y else y + if (y == null) return if (y != null) y else y val z: Int? = null if (z != null) return if (z == null) z else z - return z + return z } diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ThisSuper.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ThisSuper.kt index 02af52d4470..639a0abd7ee 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ThisSuper.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/ThisSuper.kt @@ -16,6 +16,6 @@ class Derived : Base() { val y: Int? = null if (y != null) super.bar(this.baz(y)) - else this.baz(super.bar(y)) + else this.baz(super.bar(y)) } } diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/Throw.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/Throw.kt index 11762476d12..daba3a817f0 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/Throw.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/Throw.kt @@ -3,7 +3,7 @@ fun bar(x: Int): RuntimeException = RuntimeException(x.toString()) fun foo() { val x: Int? = null - if (x == null) throw bar(x) + if (x == null) throw bar(x) throw bar(x) throw bar(x) } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/While.kt b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/While.kt index 945f49932fa..fd01fee12cb 100644 --- a/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/While.kt +++ b/compiler/testData/diagnostics/tests/dataFlowInfoTraversal/While.kt @@ -3,7 +3,7 @@ fun bar(x: Int): Int = x + 1 fun foo() { val x: Int? = null while (x == null) { - bar(x) + bar(x) } bar(x) @@ -11,11 +11,11 @@ fun foo() { while (y != null) { bar(y) } - bar(y) + bar(y) val z: Int? = null while (z == null) { - bar(z) + bar(z) break } bar(z) diff --git a/compiler/testData/diagnostics/tests/declarationChecks/FunctionWithMissingNames.kt b/compiler/testData/diagnostics/tests/declarationChecks/FunctionWithMissingNames.kt index 247d5892d79..2e3778aa182 100644 --- a/compiler/testData/diagnostics/tests/declarationChecks/FunctionWithMissingNames.kt +++ b/compiler/testData/diagnostics/tests/declarationChecks/FunctionWithMissingNames.kt @@ -3,17 +3,17 @@ annotation class a interface A interface B -fun () {} -fun A.() {} +fun () {} +fun A.() {} -@a fun () {} -fun @a A.() {} +@a fun () {} +fun @a A.() {} class Outer { - fun () {} + fun () {} fun B.() {} - @a fun () {} + @a fun () {} fun @a A.() {} } diff --git a/compiler/testData/diagnostics/tests/declarationChecks/LocalVariableWithNoTypeInformation.kt b/compiler/testData/diagnostics/tests/declarationChecks/LocalVariableWithNoTypeInformation.kt index 592a462d586..50c309fa4d6 100644 --- a/compiler/testData/diagnostics/tests/declarationChecks/LocalVariableWithNoTypeInformation.kt +++ b/compiler/testData/diagnostics/tests/declarationChecks/LocalVariableWithNoTypeInformation.kt @@ -1,3 +1,3 @@ fun test() { - val a + val a } diff --git a/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/ForLoopMissingLoopParameter.kt b/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/ForLoopMissingLoopParameter.kt index 4215add1e0d..9b5dba7c613 100644 --- a/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/ForLoopMissingLoopParameter.kt +++ b/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/ForLoopMissingLoopParameter.kt @@ -1,8 +1,8 @@ // !WITH_NEW_INFERENCE fun useDeclaredVariables() { for ((a, b)) { - a - b + a + b } } diff --git a/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/destructuringDeclarationAssignedUnresolved.kt b/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/destructuringDeclarationAssignedUnresolved.kt index 145735a840c..c19fbf84ee8 100644 --- a/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/destructuringDeclarationAssignedUnresolved.kt +++ b/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/destructuringDeclarationAssignedUnresolved.kt @@ -1,7 +1,7 @@ fun useDeclaredVariables() { val (a, b) = unresolved - a - b + a + b } fun checkersShouldRun() { diff --git a/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/destructuringDeclarationMissingInitializer.kt b/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/destructuringDeclarationMissingInitializer.kt index b8bb6e327dd..6de91aca333 100644 --- a/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/destructuringDeclarationMissingInitializer.kt +++ b/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/destructuringDeclarationMissingInitializer.kt @@ -1,7 +1,7 @@ fun useDeclaredVariables() { val (a, b) - a - b + a + b } fun checkersShouldRun() { diff --git a/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/underscore.kt b/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/underscore.kt index de77a4a7c93..786d0a55f99 100644 --- a/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/underscore.kt +++ b/compiler/testData/diagnostics/tests/declarationChecks/destructuringDeclarations/underscore.kt @@ -43,7 +43,7 @@ fun test() { val (_, `_`) = A() - foo(_, y) + foo(_, y) val (unused, _) = A() } diff --git a/compiler/testData/diagnostics/tests/declarationChecks/localDeclarationModifiers.kt b/compiler/testData/diagnostics/tests/declarationChecks/localDeclarationModifiers.kt index d816dd7182f..7cd5681ab25 100644 --- a/compiler/testData/diagnostics/tests/declarationChecks/localDeclarationModifiers.kt +++ b/compiler/testData/diagnostics/tests/declarationChecks/localDeclarationModifiers.kt @@ -6,7 +6,7 @@ class T { fun foo() { public val i = 11 - abstract val j + abstract val j override fun T.baz() = 2 private fun bar() = 2 } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/delegatedProperty/provideDelegate/setValue.kt b/compiler/testData/diagnostics/tests/delegatedProperty/provideDelegate/setValue.kt index 06cb917614c..17274dcb27d 100644 --- a/compiler/testData/diagnostics/tests/delegatedProperty/provideDelegate/setValue.kt +++ b/compiler/testData/diagnostics/tests/delegatedProperty/provideDelegate/setValue.kt @@ -11,7 +11,7 @@ operator fun String.provideDelegate(receiver: Any?, p: Any) = Delegate() var test1: String by Delegate() var test2: String by Delegate() -var test3: String by "OK" +var test3: String by "OK" var test4: String by "OK".provideDelegate(null, "") var test5: String by "OK".provideDelegate(null, "") \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/delegatedProperty/recursiveType.kt b/compiler/testData/diagnostics/tests/delegatedProperty/recursiveType.kt index c03053ddd7e..8d64edc5bf6 100644 --- a/compiler/testData/diagnostics/tests/delegatedProperty/recursiveType.kt +++ b/compiler/testData/diagnostics/tests/delegatedProperty/recursiveType.kt @@ -8,7 +8,7 @@ val a by b) -val c by d +val c by d val d by c class Delegate(i: Int) { diff --git a/compiler/testData/diagnostics/tests/delegation/DelegationToJavaIface.kt b/compiler/testData/diagnostics/tests/delegation/DelegationToJavaIface.kt index 38d91fa982d..570a40e173e 100644 --- a/compiler/testData/diagnostics/tests/delegation/DelegationToJavaIface.kt +++ b/compiler/testData/diagnostics/tests/delegation/DelegationToJavaIface.kt @@ -1,4 +1,4 @@ // JAVAC_EXPECTED_FILE class TestIface(r : Runnable) : Runnable by r {} -class TestObject(o : Object) : Object by o {} \ No newline at end of file +class TestObject(o : Object) : Object by o {} \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/delegation/covariantOverrides/fromClass.kt b/compiler/testData/diagnostics/tests/delegation/covariantOverrides/fromClass.kt index f97ee93a280..ddaaec96f72 100644 --- a/compiler/testData/diagnostics/tests/delegation/covariantOverrides/fromClass.kt +++ b/compiler/testData/diagnostics/tests/delegation/covariantOverrides/fromClass.kt @@ -6,7 +6,7 @@ open class IDerived1 : IBase1 { override fun foo(): String = "1" } -class Broken1(val b: IBase1) : IBase1 by b, IDerived1() +class Broken1(val b: IBase1) : IBase1 by b, IDerived1() interface IBase2 { val foo: Any @@ -16,4 +16,4 @@ open class IDerived2 : IBase2 { override val foo: String = "2" } -class Broken2(val b: IBase2) : IBase2 by b, IDerived2() +class Broken2(val b: IBase2) : IBase2 by b, IDerived2() diff --git a/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/diamond.kt b/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/diamond.kt index 5d4dc4857a9..61dd6580443 100644 --- a/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/diamond.kt +++ b/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/diamond.kt @@ -23,19 +23,19 @@ class ImplAll : Base, Base2, Base3 { } fun box(): String { - object : Base2, Base3, Base by Impl() { + object : Base2, Base3, Base by Impl() { } - object : Base2 by Impl2(), Base3, Base { + object : Base2 by Impl2(), Base3, Base { } - object : Base2, Base3 by Impl3(), Base { + object : Base2, Base3 by Impl3(), Base { } - object : Base2 by Impl2(), Base3 by Impl3(), Base by Impl() { + object : Base2 by Impl2(), Base3 by Impl3(), Base by Impl() { } diff --git a/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/sameDelegationInHierarchy2.kt b/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/sameDelegationInHierarchy2.kt index 72be577b870..91de29cdf30 100644 --- a/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/sameDelegationInHierarchy2.kt +++ b/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/sameDelegationInHierarchy2.kt @@ -14,7 +14,7 @@ class Delegate : Derived { public open class MyClass : Base by Delegate() fun box(): String { - object : MyClass(), Derived by Delegate() { + object : MyClass(), Derived by Delegate() { } return "OK" } diff --git a/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/severalDelegates.kt b/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/severalDelegates.kt index 8ccce102da5..1ff9963b1ee 100644 --- a/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/severalDelegates.kt +++ b/compiler/testData/diagnostics/tests/delegation/memberHidesSupertypeOverride/severalDelegates.kt @@ -23,6 +23,6 @@ public abstract class MyClass : Base1, Base2 { } } -class A : MyClass(), Base1 by Delegate1(), Base1 by Delegate2() { +class A : MyClass(), Base1 by Delegate1(), Base1 by Delegate2() { } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/duplicateJvmSignature/missingNames.kt b/compiler/testData/diagnostics/tests/duplicateJvmSignature/missingNames.kt index 96770388a9c..a6bc8ff3831 100644 --- a/compiler/testData/diagnostics/tests/duplicateJvmSignature/missingNames.kt +++ b/compiler/testData/diagnostics/tests/duplicateJvmSignature/missingNames.kt @@ -1,5 +1,5 @@ // !DIAGNOSTICS: -DUPLICATE_CLASS_NAMES -fun () { +fun () { } diff --git a/compiler/testData/diagnostics/tests/dynamicTypes/withInvisibleSynthesized.kt b/compiler/testData/diagnostics/tests/dynamicTypes/withInvisibleSynthesized.kt index 768784939f9..f2ff95977a5 100644 --- a/compiler/testData/diagnostics/tests/dynamicTypes/withInvisibleSynthesized.kt +++ b/compiler/testData/diagnostics/tests/dynamicTypes/withInvisibleSynthesized.kt @@ -20,7 +20,7 @@ public class J { import p.* class K: J.C() { - fun dynamic.test() { + fun dynamic.test() { sam(null) sam( name = null, diff --git a/compiler/testData/diagnostics/tests/enum/enumInheritance.kt b/compiler/testData/diagnostics/tests/enum/enumInheritance.kt index ff0f2a425fc..60e7887cefc 100644 --- a/compiler/testData/diagnostics/tests/enum/enumInheritance.kt +++ b/compiler/testData/diagnostics/tests/enum/enumInheritance.kt @@ -1,7 +1,7 @@ // FILE: test.kt enum class MyEnum(): MyClass() {} enum class MyEnum2(): MyTrait {} -enum class MyEnum3(): MyEnumBase() {} +enum class MyEnum3(): MyEnumBase() {} open class MyClass() {} diff --git a/compiler/testData/diagnostics/tests/enum/inheritanceFromEnum.kt b/compiler/testData/diagnostics/tests/enum/inheritanceFromEnum.kt index b4f3ac1e3a4..67b5b7daba8 100644 --- a/compiler/testData/diagnostics/tests/enum/inheritanceFromEnum.kt +++ b/compiler/testData/diagnostics/tests/enum/inheritanceFromEnum.kt @@ -8,6 +8,6 @@ public enum MyJavaEnum {} enum class MyEnum2() {} -class MyClass(): MyEnum2() {} +class MyClass(): MyEnum2() {} class MyClass2(): MyJavaEnum() {} diff --git a/compiler/testData/diagnostics/tests/evaluate/divisionByZero.kt b/compiler/testData/diagnostics/tests/evaluate/divisionByZero.kt index 63c018a72c0..ea1c09a76d5 100644 --- a/compiler/testData/diagnostics/tests/evaluate/divisionByZero.kt +++ b/compiler/testData/diagnostics/tests/evaluate/divisionByZero.kt @@ -12,7 +12,7 @@ val a7 = 1.div(a1) val a8 = 1.div(a2) val a9 = 2 * (1.div(0)) -val b1: Byte = 1 / 0 -@Ann(1 / 0) val b2 = 1 +val b1: Byte = 1 / 0 +@Ann(1 / 0) val b2 = 1 annotation class Ann(val i : Int) \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/functionLiterals/ExpectedParametersTypesMismatch.kt b/compiler/testData/diagnostics/tests/functionLiterals/ExpectedParametersTypesMismatch.kt index ce65a8f7486..cb87406a4d8 100644 --- a/compiler/testData/diagnostics/tests/functionLiterals/ExpectedParametersTypesMismatch.kt +++ b/compiler/testData/diagnostics/tests/functionLiterals/ExpectedParametersTypesMismatch.kt @@ -26,7 +26,7 @@ fun test1() { x, y -> "" } foo1 { - -> 42 + -> 42 } @@ -40,6 +40,6 @@ fun test1() { x -> "" } foo2 { - -> 42 + -> 42 } } diff --git a/compiler/testData/diagnostics/tests/functionLiterals/return/unresolvedReferenceInReturnBlock.kt b/compiler/testData/diagnostics/tests/functionLiterals/return/unresolvedReferenceInReturnBlock.kt index c553b404621..318589a70ab 100644 --- a/compiler/testData/diagnostics/tests/functionLiterals/return/unresolvedReferenceInReturnBlock.kt +++ b/compiler/testData/diagnostics/tests/functionLiterals/return/unresolvedReferenceInReturnBlock.kt @@ -5,5 +5,5 @@ val a = l@ { val b = l@ { if ("" == "OK") return@l - return@l r + return@l r } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/generics/projectionsScope/projectedOutSmartCast.kt b/compiler/testData/diagnostics/tests/generics/projectionsScope/projectedOutSmartCast.kt index a9c1c6fa511..32877a619a6 100644 --- a/compiler/testData/diagnostics/tests/generics/projectionsScope/projectedOutSmartCast.kt +++ b/compiler/testData/diagnostics/tests/generics/projectionsScope/projectedOutSmartCast.kt @@ -17,7 +17,7 @@ fun foo(x: Any?, y: C<*>) { with(x) { if (this is C<*>) { - bindTo("") + bindTo("") } } } diff --git a/compiler/testData/diagnostics/tests/imports/ImportOverloadFunctions.kt b/compiler/testData/diagnostics/tests/imports/ImportOverloadFunctions.kt index 325bbe9e0aa..223bc346c43 100644 --- a/compiler/testData/diagnostics/tests/imports/ImportOverloadFunctions.kt +++ b/compiler/testData/diagnostics/tests/imports/ImportOverloadFunctions.kt @@ -21,7 +21,7 @@ fun all(a: String) {} // FILE: 2.kt -import k.zero +import k.zero import k.one import k.two import k.all diff --git a/compiler/testData/diagnostics/tests/imports/PackageLocalClassReferencedError.kt b/compiler/testData/diagnostics/tests/imports/PackageLocalClassReferencedError.kt index fd756a7e265..1919f02f6de 100644 --- a/compiler/testData/diagnostics/tests/imports/PackageLocalClassReferencedError.kt +++ b/compiler/testData/diagnostics/tests/imports/PackageLocalClassReferencedError.kt @@ -8,4 +8,4 @@ package a import pack1.* -private class X : SomeClass() \ No newline at end of file +private class X : SomeClass() \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/imports/PrivateClassReferencedError.kt b/compiler/testData/diagnostics/tests/imports/PrivateClassReferencedError.kt index b8cf2d32a2f..496ea86f828 100644 --- a/compiler/testData/diagnostics/tests/imports/PrivateClassReferencedError.kt +++ b/compiler/testData/diagnostics/tests/imports/PrivateClassReferencedError.kt @@ -11,4 +11,4 @@ package a import pack1.SomeClass.* -private class X : N() \ No newline at end of file +private class X : N() \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/incompleteCode/checkNothingIsSubtype.kt b/compiler/testData/diagnostics/tests/incompleteCode/checkNothingIsSubtype.kt index 2ae7ece0c1d..32df9a0b9aa 100644 --- a/compiler/testData/diagnostics/tests/incompleteCode/checkNothingIsSubtype.kt +++ b/compiler/testData/diagnostics/tests/incompleteCode/checkNothingIsSubtype.kt @@ -7,7 +7,7 @@ interface A fun infer(a: A) : T {} fun test(nothing: Nothing?) { - val i = infer(nothing) + val i = infer(nothing) } fun sum(a : IntArray) : Int { diff --git a/compiler/testData/diagnostics/tests/incompleteCode/kt2014.kt b/compiler/testData/diagnostics/tests/incompleteCode/kt2014.kt index 5e88a21ab2a..63cec9e0adc 100644 --- a/compiler/testData/diagnostics/tests/incompleteCode/kt2014.kt +++ b/compiler/testData/diagnostics/tests/incompleteCode/kt2014.kt @@ -10,7 +10,7 @@ class Foo { fun x(f : Foo) { f.prop - f.bar + f.bar f.a() c() diff --git a/compiler/testData/diagnostics/tests/inline/parenthesized.kt b/compiler/testData/diagnostics/tests/inline/parenthesized.kt index 046f9755a7f..35ffeead895 100644 --- a/compiler/testData/diagnostics/tests/inline/parenthesized.kt +++ b/compiler/testData/diagnostics/tests/inline/parenthesized.kt @@ -4,7 +4,7 @@ inline fun inlineFunWithInvoke(s: (p: Int) -> Unit) { (s)(11) (s).invoke(11) (s) invoke 11 - (s) + (s) } inline fun Function1.inlineExt() { @@ -18,7 +18,7 @@ inline fun inlineFunWithInvoke2(s: (p: Int) -> Unit) { (((s)))(11) (((s))).invoke(11) (((s))) invoke 11 - (((s))) + (((s))) } inline fun propagation(s: (p: Int) -> Unit) { diff --git a/compiler/testData/diagnostics/tests/inline/sam.kt b/compiler/testData/diagnostics/tests/inline/sam.kt index 2a0b0d86cab..39b4fbc83a3 100644 --- a/compiler/testData/diagnostics/tests/inline/sam.kt +++ b/compiler/testData/diagnostics/tests/inline/sam.kt @@ -22,8 +22,8 @@ inline fun inlineFunWithInvoke(s: (p: Int) -> Unit, ext: Int.(p: Int) -> Unit) { 11.ext(11) 11 ext 11 - s - ext + s + ext 11 } } @@ -38,7 +38,7 @@ inline fun inlineFunWithInvokeNonInline(noinline s: (p: Int) -> Unit, ext: Int.( 11 ext 11 s - ext + ext 11 } diff --git a/compiler/testData/diagnostics/tests/inner/classesInClassObjectHeader.kt b/compiler/testData/diagnostics/tests/inner/classesInClassObjectHeader.kt index 1702c497333..e441ee22671 100644 --- a/compiler/testData/diagnostics/tests/inner/classesInClassObjectHeader.kt +++ b/compiler/testData/diagnostics/tests/inner/classesInClassObjectHeader.kt @@ -1,6 +1,6 @@ class Test { @`InnerAnnotation` @InnerAnnotation - companion object : StaticClass(), InnerClass() { + companion object : StaticClass(), InnerClass() { } diff --git a/compiler/testData/diagnostics/tests/inner/innerErrorForClassObjects.kt b/compiler/testData/diagnostics/tests/inner/innerErrorForClassObjects.kt index 42df6333fee..696fffe1bb4 100644 --- a/compiler/testData/diagnostics/tests/inner/innerErrorForClassObjects.kt +++ b/compiler/testData/diagnostics/tests/inner/innerErrorForClassObjects.kt @@ -5,8 +5,8 @@ class TestSome

{ } class Test { - companion object : InnerClass() { - val a = object: InnerClass() { + companion object : InnerClass() { + val a = object: InnerClass() { } fun more(): InnerClass { diff --git a/compiler/testData/diagnostics/tests/inner/innerErrorForObjects.kt b/compiler/testData/diagnostics/tests/inner/innerErrorForObjects.kt index e2752bf0eba..bb960cc2405 100644 --- a/compiler/testData/diagnostics/tests/inner/innerErrorForObjects.kt +++ b/compiler/testData/diagnostics/tests/inner/innerErrorForObjects.kt @@ -5,8 +5,8 @@ class TestSome

{ } class Test { - object Some : InnerClass() { - val a = object: InnerClass() { + object Some : InnerClass() { + val a = object: InnerClass() { } fun more(): InnerClass { diff --git a/compiler/testData/diagnostics/tests/inner/modality.kt b/compiler/testData/diagnostics/tests/inner/modality.kt index 693081811fd..db8da383fe9 100644 --- a/compiler/testData/diagnostics/tests/inner/modality.kt +++ b/compiler/testData/diagnostics/tests/inner/modality.kt @@ -7,7 +7,7 @@ class Outer { class Nested1 : OpenNested() class Nested2 : FinalNested() - class Nested3 : OpenInner() + class Nested3 : OpenInner() class Nested4 : FinalInner() inner class Inner1 : OpenNested() diff --git a/compiler/testData/diagnostics/tests/inner/nestedClassAccessedViaInstanceReference.kt b/compiler/testData/diagnostics/tests/inner/nestedClassAccessedViaInstanceReference.kt index 25cc3aac86b..8a773d7b240 100644 --- a/compiler/testData/diagnostics/tests/inner/nestedClassAccessedViaInstanceReference.kt +++ b/compiler/testData/diagnostics/tests/inner/nestedClassAccessedViaInstanceReference.kt @@ -25,28 +25,28 @@ object Obj { fun test(with: WithClassObject, without: WithoutClassObject, obj: Obj) { with.Nested() - with.NestedWithClassObject + with.NestedWithClassObject with.NestedWithClassObject() - with.NestedWithClassObject.foo() - with.NestedEnum.A + with.NestedWithClassObject.foo() + with.NestedEnum.A with.NestedObj with.NestedObj() with.NestedObj.foo() without.Nested() - without.NestedWithClassObject + without.NestedWithClassObject without.NestedWithClassObject() - without.NestedWithClassObject.foo() - without.NestedEnum.A + without.NestedWithClassObject.foo() + without.NestedEnum.A without.NestedObj without.NestedObj() without.NestedObj.foo() obj.Nested() - obj.NestedWithClassObject + obj.NestedWithClassObject obj.NestedWithClassObject() - obj.NestedWithClassObject.foo() - obj.NestedEnum.A + obj.NestedWithClassObject.foo() + obj.NestedEnum.A obj.NestedObj obj.NestedObj() obj.NestedObj.foo() diff --git a/compiler/testData/diagnostics/tests/j+k/recursionWithJavaSyntheticProperty.kt b/compiler/testData/diagnostics/tests/j+k/recursionWithJavaSyntheticProperty.kt index db64efbde5c..3580249bf80 100644 --- a/compiler/testData/diagnostics/tests/j+k/recursionWithJavaSyntheticProperty.kt +++ b/compiler/testData/diagnostics/tests/j+k/recursionWithJavaSyntheticProperty.kt @@ -8,5 +8,5 @@ public class X { class A : X() { // TODO: DEBUG_INFO_MISSING_UNRESOLVED indicates a bug here - override fun getFoo() = foo + override fun getFoo() = foo } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/kt310.kt b/compiler/testData/diagnostics/tests/kt310.kt index 8ed71ce728f..d6418045280 100644 --- a/compiler/testData/diagnostics/tests/kt310.kt +++ b/compiler/testData/diagnostics/tests/kt310.kt @@ -1,5 +1,5 @@ // !WITH_NEW_INFERENCE fun f(c: LongRange): Int { - return c.start() + return c.start() } diff --git a/compiler/testData/diagnostics/tests/modifiers/IllegalModifiers.kt b/compiler/testData/diagnostics/tests/modifiers/IllegalModifiers.kt index 5318cfdfede..eac597e4a5d 100644 --- a/compiler/testData/diagnostics/tests/modifiers/IllegalModifiers.kt +++ b/compiler/testData/diagnostics/tests/modifiers/IllegalModifiers.kt @@ -87,7 +87,7 @@ abstract class IllegalModifiers6() { public @annotated init {} - private @IllegalModifiers6() init {} + private @IllegalModifiers6() init {} } // strange inappropriate modifiers usages diff --git a/compiler/testData/diagnostics/tests/modifiers/const/types.kt b/compiler/testData/diagnostics/tests/modifiers/const/types.kt index 674e83339b8..dd7b10405fb 100644 --- a/compiler/testData/diagnostics/tests/modifiers/const/types.kt +++ b/compiler/testData/diagnostics/tests/modifiers/const/types.kt @@ -13,5 +13,5 @@ enum class MyEnum { A } const val unresolvedConst1 = Unresolved const var unresolvedConst2 = Unresolved -const val unresolvedConst3 = Unresolved +const val unresolvedConst3 = Unresolved get() = 10 diff --git a/compiler/testData/diagnostics/tests/multiplatform/enum/constructorInHeaderEnum.kt b/compiler/testData/diagnostics/tests/multiplatform/enum/constructorInHeaderEnum.kt index c45a1bbf519..f12cc694024 100644 --- a/compiler/testData/diagnostics/tests/multiplatform/enum/constructorInHeaderEnum.kt +++ b/compiler/testData/diagnostics/tests/multiplatform/enum/constructorInHeaderEnum.kt @@ -11,5 +11,5 @@ expect enum class En(x: Int) { } expect enum class En2 { - E1() + E1() } diff --git a/compiler/testData/diagnostics/tests/multiplatform/headerClass/baseExpectClassWithoutConstructor.kt b/compiler/testData/diagnostics/tests/multiplatform/headerClass/baseExpectClassWithoutConstructor.kt index 69e9678e471..7951a02092f 100644 --- a/compiler/testData/diagnostics/tests/multiplatform/headerClass/baseExpectClassWithoutConstructor.kt +++ b/compiler/testData/diagnostics/tests/multiplatform/headerClass/baseExpectClassWithoutConstructor.kt @@ -4,7 +4,7 @@ expect open class A expect class B : A -open class C : A +open class C : A // MODULE: m1-jvm(m1-common) // FILE: jvm.kt diff --git a/compiler/testData/diagnostics/tests/multiplatform/headerClass/expectDeclarationWithWeakIncompatibilities.kt b/compiler/testData/diagnostics/tests/multiplatform/headerClass/expectDeclarationWithWeakIncompatibilities.kt index 64dabad62b0..c9ae7381976 100644 --- a/compiler/testData/diagnostics/tests/multiplatform/headerClass/expectDeclarationWithWeakIncompatibilities.kt +++ b/compiler/testData/diagnostics/tests/multiplatform/headerClass/expectDeclarationWithWeakIncompatibilities.kt @@ -23,6 +23,6 @@ actual var s: String = "value" fun foo2(): Int = 0 -actual class Foo3 +actual class Foo3 -class Foo3 +class Foo3 diff --git a/compiler/testData/diagnostics/tests/multiplatform/headerClass/extraHeaderOnMembers.kt b/compiler/testData/diagnostics/tests/multiplatform/headerClass/extraHeaderOnMembers.kt index ffcd9272a1b..e2802eb26a2 100644 --- a/compiler/testData/diagnostics/tests/multiplatform/headerClass/extraHeaderOnMembers.kt +++ b/compiler/testData/diagnostics/tests/multiplatform/headerClass/extraHeaderOnMembers.kt @@ -3,7 +3,7 @@ // FILE: common.kt expect class H { - expect fun foo() + expect fun foo() } // MODULE: m1-jvm(m1-common) diff --git a/compiler/testData/diagnostics/tests/multiplatform/headerClass/nestedClassesWithErrors.kt b/compiler/testData/diagnostics/tests/multiplatform/headerClass/nestedClassesWithErrors.kt index 275ddef2043..fed08086bf3 100644 --- a/compiler/testData/diagnostics/tests/multiplatform/headerClass/nestedClassesWithErrors.kt +++ b/compiler/testData/diagnostics/tests/multiplatform/headerClass/nestedClassesWithErrors.kt @@ -5,14 +5,14 @@ expect class B { class N { fun body() {} - expect fun extraHeader() + expect fun extraHeader() } } expect class C { - expect class N - expect enum class E - expect inner class I + expect class N + expect enum class E + expect inner class I } expect class D { diff --git a/compiler/testData/diagnostics/tests/multiplatform/headerClass/superClass.kt b/compiler/testData/diagnostics/tests/multiplatform/headerClass/superClass.kt index 61548794f20..37707af6feb 100644 --- a/compiler/testData/diagnostics/tests/multiplatform/headerClass/superClass.kt +++ b/compiler/testData/diagnostics/tests/multiplatform/headerClass/superClass.kt @@ -8,7 +8,7 @@ interface J expect class Foo : I, C, J -expect class Bar : C() +expect class Bar : C() // MODULE: m2-jvm(m1-common) // FILE: jvm.kt diff --git a/compiler/testData/diagnostics/tests/multiplatform/headerFunInNonHeaderClass.kt b/compiler/testData/diagnostics/tests/multiplatform/headerFunInNonHeaderClass.kt index b04f0649f28..e2e30547342 100644 --- a/compiler/testData/diagnostics/tests/multiplatform/headerFunInNonHeaderClass.kt +++ b/compiler/testData/diagnostics/tests/multiplatform/headerFunInNonHeaderClass.kt @@ -3,7 +3,7 @@ // FILE: common.kt class Foo { - expect fun bar(): String + expect fun bar(): String } // MODULE: m1-jvm(m1-common) diff --git a/compiler/testData/diagnostics/tests/nullabilityAndSmartCasts/kt2146.kt b/compiler/testData/diagnostics/tests/nullabilityAndSmartCasts/kt2146.kt index aa12cbaf575..073e4f2e281 100644 --- a/compiler/testData/diagnostics/tests/nullabilityAndSmartCasts/kt2146.kt +++ b/compiler/testData/diagnostics/tests/nullabilityAndSmartCasts/kt2146.kt @@ -26,7 +26,7 @@ fun f3(s: Int?): Int { fun f4(s: Int?): Int { return when { s == 4 -> s - s == null -> s + s == null -> s else -> s } } diff --git a/compiler/testData/diagnostics/tests/nullabilityAndSmartCasts/kt2164.kt b/compiler/testData/diagnostics/tests/nullabilityAndSmartCasts/kt2164.kt index 8037571281d..0b4f9a7dc02 100644 --- a/compiler/testData/diagnostics/tests/nullabilityAndSmartCasts/kt2164.kt +++ b/compiler/testData/diagnostics/tests/nullabilityAndSmartCasts/kt2164.kt @@ -22,7 +22,7 @@ fun main() { foo(x!!) foo(x) } else { - foo(x) + foo(x) foo(x!!) foo(x) } diff --git a/compiler/testData/diagnostics/tests/numbers/intValuesOutOfRange.kt b/compiler/testData/diagnostics/tests/numbers/intValuesOutOfRange.kt index 74bd4f14a30..2bbe756f018 100644 --- a/compiler/testData/diagnostics/tests/numbers/intValuesOutOfRange.kt +++ b/compiler/testData/diagnostics/tests/numbers/intValuesOutOfRange.kt @@ -13,5 +13,5 @@ fun main() { //not 'An integer literal does not conform to the expected type Int/Long' val l: Long = 1111111111111117777777777777777 foo(11111111111111177777777777777) - bar(11111111111111177777777777777) + bar(11111111111111177777777777777) } diff --git a/compiler/testData/diagnostics/tests/override/MissingDelegate.kt b/compiler/testData/diagnostics/tests/override/MissingDelegate.kt index 0411f893a24..11a1b422b4d 100644 --- a/compiler/testData/diagnostics/tests/override/MissingDelegate.kt +++ b/compiler/testData/diagnostics/tests/override/MissingDelegate.kt @@ -1,3 +1,3 @@ -class C : Base1 by Base2(1) { +class C : Base1 by Base2(1) { fun test() { } } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/override/MultipleDefaultsAndNamesInSupertypes.kt b/compiler/testData/diagnostics/tests/override/MultipleDefaultsAndNamesInSupertypes.kt index fae82e55ad3..e500fde68b2 100644 --- a/compiler/testData/diagnostics/tests/override/MultipleDefaultsAndNamesInSupertypes.kt +++ b/compiler/testData/diagnostics/tests/override/MultipleDefaultsAndNamesInSupertypes.kt @@ -11,4 +11,4 @@ interface C { } // TODO DIFFERENT_NAMES_FOR_THE_SAME_PARAMETER_IN_SUPERTYPES reported twice -class Z : A, B(), C \ No newline at end of file +class Z : A, B(), C \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/override/ObjectDelegationManyImpl.kt b/compiler/testData/diagnostics/tests/override/ObjectDelegationManyImpl.kt index 523d8d4b97f..e18871edaae 100644 --- a/compiler/testData/diagnostics/tests/override/ObjectDelegationManyImpl.kt +++ b/compiler/testData/diagnostics/tests/override/ObjectDelegationManyImpl.kt @@ -10,4 +10,4 @@ object Impl : D, E { override fun foo() {} } -val obj: D = object : D by Impl, E by Impl {} \ No newline at end of file +val obj: D = object : D by Impl, E by Impl {} \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/override/clashesOnInheritance/covariantOverrides.kt b/compiler/testData/diagnostics/tests/override/clashesOnInheritance/covariantOverrides.kt index 75fd18a1ed8..d2e62a5b314 100644 --- a/compiler/testData/diagnostics/tests/override/clashesOnInheritance/covariantOverrides.kt +++ b/compiler/testData/diagnostics/tests/override/clashesOnInheritance/covariantOverrides.kt @@ -19,7 +19,7 @@ interface IDerived : ILeft, IRight { } // Error: ILeft::copy and IRight::copy have unrelated return types -class CDerivedInvalid1 : ILeft, IRight +class CDerivedInvalid1 : ILeft, IRight // Error: CLeft::copy and IRight::copy have unrelated return types class CDerivedInvalid2 : CLeft(), IRight diff --git a/compiler/testData/diagnostics/tests/platformTypes/genericVarianceViolation/smartCast.kt b/compiler/testData/diagnostics/tests/platformTypes/genericVarianceViolation/smartCast.kt index 7a7e03f21a2..7cc85c1179a 100644 --- a/compiler/testData/diagnostics/tests/platformTypes/genericVarianceViolation/smartCast.kt +++ b/compiler/testData/diagnostics/tests/platformTypes/genericVarianceViolation/smartCast.kt @@ -10,7 +10,7 @@ public class A { fun main(a: A, ml: Any) { if (ml is MutableList) { - a.foo(ml) + a.foo(ml) a.foo(ml as List) } } diff --git a/compiler/testData/diagnostics/tests/platformTypes/nullabilityWarnings/arithmetic.kt b/compiler/testData/diagnostics/tests/platformTypes/nullabilityWarnings/arithmetic.kt index c04b26a0a7a..a6b574a0b63 100644 --- a/compiler/testData/diagnostics/tests/platformTypes/nullabilityWarnings/arithmetic.kt +++ b/compiler/testData/diagnostics/tests/platformTypes/nullabilityWarnings/arithmetic.kt @@ -46,7 +46,7 @@ fun test() { 1 plus platformJ platformNN plus 1 - platformN plus 1 + platformN plus 1 platformJ plus 1 platformNN += 1 diff --git a/compiler/testData/diagnostics/tests/privateInFile/topLevelAnnotationCall.kt b/compiler/testData/diagnostics/tests/privateInFile/topLevelAnnotationCall.kt index ddb17d56242..c2cac9d5cce 100644 --- a/compiler/testData/diagnostics/tests/privateInFile/topLevelAnnotationCall.kt +++ b/compiler/testData/diagnostics/tests/privateInFile/topLevelAnnotationCall.kt @@ -17,11 +17,11 @@ class C1 // FILE: 2.kt package pp -@A(foo) +@A(foo) fun f2() {} -@A(foo) +@A(foo) val p2 = "" -@A(foo) +@A(foo) class C2 diff --git a/compiler/testData/diagnostics/tests/privateInFile/visibility.kt b/compiler/testData/diagnostics/tests/privateInFile/visibility.kt index 3659d6217b7..5ada8b96872 100644 --- a/compiler/testData/diagnostics/tests/privateInFile/visibility.kt +++ b/compiler/testData/diagnostics/tests/privateInFile/visibility.kt @@ -43,7 +43,7 @@ fun test() { xx = 40 } -class B : A() {} +class B : A() {} class Q { class W { diff --git a/compiler/testData/diagnostics/tests/recovery/namelessToplevelDeclarations.kt b/compiler/testData/diagnostics/tests/recovery/namelessToplevelDeclarations.kt index 2074c1a18ca..a3eb5de641b 100644 --- a/compiler/testData/diagnostics/tests/recovery/namelessToplevelDeclarations.kt +++ b/compiler/testData/diagnostics/tests/recovery/namelessToplevelDeclarations.kt @@ -2,7 +2,7 @@ package -fun () { +fun () { } diff --git a/compiler/testData/diagnostics/tests/regressions/Jet81.kt b/compiler/testData/diagnostics/tests/regressions/Jet81.kt index 7e127490b1d..ec2e379b22b 100644 --- a/compiler/testData/diagnostics/tests/regressions/Jet81.kt +++ b/compiler/testData/diagnostics/tests/regressions/Jet81.kt @@ -18,9 +18,9 @@ object A { class Test2 { private val a = object { init { - b + 1 + b + 1 } - val x = b + val x = b val y = 1 } diff --git a/compiler/testData/diagnostics/tests/regressions/kt10843.kt b/compiler/testData/diagnostics/tests/regressions/kt10843.kt index a3968e8f13c..02061727110 100644 --- a/compiler/testData/diagnostics/tests/regressions/kt10843.kt +++ b/compiler/testData/diagnostics/tests/regressions/kt10843.kt @@ -1,7 +1,7 @@ // !WITH_NEW_INFERENCE // NI_EXPECTED_FILE // See EA-76890 / KT-10843: NPE during analysis -fun lambda(x : Int?) = x?.let l { +fun lambda(x : Int?) = x?.let l { y -> if (y > 0) return@l x y diff --git a/compiler/testData/diagnostics/tests/resolve/noCandidates/resolvedToClassifierWithReceiver.kt b/compiler/testData/diagnostics/tests/resolve/noCandidates/resolvedToClassifierWithReceiver.kt index 26ffabc8697..138ca4f7441 100644 --- a/compiler/testData/diagnostics/tests/resolve/noCandidates/resolvedToClassifierWithReceiver.kt +++ b/compiler/testData/diagnostics/tests/resolve/noCandidates/resolvedToClassifierWithReceiver.kt @@ -32,8 +32,8 @@ fun testY() { fun test(x: X) { val interface_as_fun = x.A() - val interface_as_val = x.A + val interface_as_val = x.A val object_as_fun = x.B() - val class_as_val = x.C + val class_as_val = x.C } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/scopes/classHeader/classParents.kt b/compiler/testData/diagnostics/tests/scopes/classHeader/classParents.kt index 9ccebc9d19b..58c3952aef6 100644 --- a/compiler/testData/diagnostics/tests/scopes/classHeader/classParents.kt +++ b/compiler/testData/diagnostics/tests/scopes/classHeader/classParents.kt @@ -2,7 +2,7 @@ interface I -class A(impl: Interface) : Nested(), Interface by impl, Inner, I<Nested, Interface, Inner> { +class A(impl: Interface) : Nested(), Interface by impl, Inner, I<Nested, Interface, Inner> { class Nested diff --git a/compiler/testData/diagnostics/tests/scopes/classHeader/companionObjectParents.kt b/compiler/testData/diagnostics/tests/scopes/classHeader/companionObjectParents.kt index 7feba245f29..7a5e2c3fe17 100644 --- a/compiler/testData/diagnostics/tests/scopes/classHeader/companionObjectParents.kt +++ b/compiler/testData/diagnostics/tests/scopes/classHeader/companionObjectParents.kt @@ -7,7 +7,7 @@ val bImpl: B.Companion.Interface get() = null!! interface A { - companion object : Nested(), Interface by aImpl, I<Nested, Interface> { + companion object : Nested(), Interface by aImpl, I<Nested, Interface> { class Nested @@ -16,7 +16,7 @@ interface A { } class B { - companion object : Nested(), Interface by aImpl, I<Nested, Interface> { + companion object : Nested(), Interface by aImpl, I<Nested, Interface> { class Nested diff --git a/compiler/testData/diagnostics/tests/scopes/classHeader/objectParents.kt b/compiler/testData/diagnostics/tests/scopes/classHeader/objectParents.kt index 80bc769e6b7..1fec4f2a60d 100644 --- a/compiler/testData/diagnostics/tests/scopes/classHeader/objectParents.kt +++ b/compiler/testData/diagnostics/tests/scopes/classHeader/objectParents.kt @@ -3,7 +3,7 @@ interface I val aImpl: A.Interface get() = null!! -object A : Nested(), Interface by aImpl, I<Nested, Interface> { +object A : Nested(), Interface by aImpl, I<Nested, Interface> { class Nested diff --git a/compiler/testData/diagnostics/tests/scopes/initializerScopeOfExtensionProperty.kt b/compiler/testData/diagnostics/tests/scopes/initializerScopeOfExtensionProperty.kt index ff518275169..d8b38e0def1 100644 --- a/compiler/testData/diagnostics/tests/scopes/initializerScopeOfExtensionProperty.kt +++ b/compiler/testData/diagnostics/tests/scopes/initializerScopeOfExtensionProperty.kt @@ -2,7 +2,7 @@ package i -val List.length = size +val List.length = size val List.length1 : Int get() = size @@ -15,7 +15,7 @@ class A { val ii : Int = 1 } -val A.foo = ii +val A.foo = ii val A.foo1 : Int get() = ii diff --git a/compiler/testData/diagnostics/tests/scopes/visibility2.kt b/compiler/testData/diagnostics/tests/scopes/visibility2.kt index ae14c01d8e2..e43e13ad56d 100644 --- a/compiler/testData/diagnostics/tests/scopes/visibility2.kt +++ b/compiler/testData/diagnostics/tests/scopes/visibility2.kt @@ -33,7 +33,7 @@ fun test() { val po = PO } -class B : A() {} +class B : A() {} class Q { class W { diff --git a/compiler/testData/diagnostics/tests/scopes/visibility3.kt b/compiler/testData/diagnostics/tests/scopes/visibility3.kt index 637a56d2103..1cded275107 100644 --- a/compiler/testData/diagnostics/tests/scopes/visibility3.kt +++ b/compiler/testData/diagnostics/tests/scopes/visibility3.kt @@ -36,7 +36,7 @@ fun test() { val po = PO } -class B : A() {} +class B : A() {} class Q { class W { diff --git a/compiler/testData/diagnostics/tests/secondaryConstructors/dataClasses.kt b/compiler/testData/diagnostics/tests/secondaryConstructors/dataClasses.kt index 0fd72e3965a..5beb17378df 100644 --- a/compiler/testData/diagnostics/tests/secondaryConstructors/dataClasses.kt +++ b/compiler/testData/diagnostics/tests/secondaryConstructors/dataClasses.kt @@ -7,7 +7,7 @@ data class A2(val y: String, val z: Int) { constructor(x: String): this(x, 0) } -data class A3 { +data class A3 { constructor() } diff --git a/compiler/testData/diagnostics/tests/smartCasts/lambdaArgumentWithBoundWithoutType.kt b/compiler/testData/diagnostics/tests/smartCasts/lambdaArgumentWithBoundWithoutType.kt index 2c178995e25..c785e34077e 100644 --- a/compiler/testData/diagnostics/tests/smartCasts/lambdaArgumentWithBoundWithoutType.kt +++ b/compiler/testData/diagnostics/tests/smartCasts/lambdaArgumentWithBoundWithoutType.kt @@ -16,7 +16,7 @@ val foo: Foo = run { val foofoo: Foo = run { val x = foo() if (x == null) throw Exception() - x + x } val bar: Bar = run { diff --git a/compiler/testData/diagnostics/tests/smartCasts/localDelegatedPropertyBefore.kt b/compiler/testData/diagnostics/tests/smartCasts/localDelegatedPropertyBefore.kt index 1eddc3a2138..a13c23e9b0f 100644 --- a/compiler/testData/diagnostics/tests/smartCasts/localDelegatedPropertyBefore.kt +++ b/compiler/testData/diagnostics/tests/smartCasts/localDelegatedPropertyBefore.kt @@ -10,6 +10,6 @@ fun failsWithClassCastException() { val sometimesNotInt: Any? by AlternatingDelegate() if (sometimesNotInt is Int) { - sometimesNotInt.inc() + sometimesNotInt.inc() } } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/smartCasts/openInSealed.kt b/compiler/testData/diagnostics/tests/smartCasts/openInSealed.kt index 737e62dc318..6579e10bc71 100644 --- a/compiler/testData/diagnostics/tests/smartCasts/openInSealed.kt +++ b/compiler/testData/diagnostics/tests/smartCasts/openInSealed.kt @@ -2,7 +2,7 @@ sealed class My(open val x: Int?) { init { if (x != null) { // Should be error: property is open - x.hashCode() + x.hashCode() } } } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/annotations.kt b/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/annotations.kt index 42042412e0f..8819464426b 100644 --- a/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/annotations.kt +++ b/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/annotations.kt @@ -6,6 +6,6 @@ annotation class Anno1(val s: String) annotation class Anno2 @SinceKotlin("1.1") constructor() -@Anno1("") -@Anno2 +@Anno1("") +@Anno2 fun t1() {} diff --git a/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/classesAndConstructors.kt b/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/classesAndConstructors.kt index a07ffd00087..28fc97bdf05 100644 --- a/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/classesAndConstructors.kt +++ b/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/classesAndConstructors.kt @@ -14,7 +14,7 @@ class Quux @SinceKotlin("1.0") constructor() fun t1(): Foo = Foo() // TODO: do not report API_NOT_AVAILABLE twice -fun t2() = object : Foo() {} +fun t2() = object : Foo() {} fun t3(): Bar? = Bar() diff --git a/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/typealiasesAsConstructors.kt b/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/typealiasesAsConstructors.kt index 05e60f83797..6c8608a99f1 100644 --- a/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/typealiasesAsConstructors.kt +++ b/compiler/testData/diagnostics/tests/sourceCompatibility/apiVersion/typealiasesAsConstructors.kt @@ -15,6 +15,6 @@ typealias C2_Alias = C2 val test1 = C1_Alias() val test2 = C2_Alias() -class Test3 : C1_Alias() +class Test3 : C1_Alias() class Test4 : C2_Alias() \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/traitWithRequired/traitSupertypeList.kt b/compiler/testData/diagnostics/tests/traitWithRequired/traitSupertypeList.kt index f6701593bc8..66325240ee1 100644 --- a/compiler/testData/diagnostics/tests/traitWithRequired/traitSupertypeList.kt +++ b/compiler/testData/diagnostics/tests/traitWithRequired/traitSupertypeList.kt @@ -6,5 +6,5 @@ interface Foo() : ba interface Foo2 : bar, Foo { } -open class Foo1() : bar(), bar, Foo, Foo() {} -open class Foo12 : bar(), bar {} \ No newline at end of file +open class Foo1() : bar(), bar, Foo, Foo() {} +open class Foo12 : bar(), bar {} \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/typeParameters/misplacedConstraints.kt b/compiler/testData/diagnostics/tests/typeParameters/misplacedConstraints.kt index 01347eb583a..83ea2ee4db9 100644 --- a/compiler/testData/diagnostics/tests/typeParameters/misplacedConstraints.kt +++ b/compiler/testData/diagnostics/tests/typeParameters/misplacedConstraints.kt @@ -1,6 +1,6 @@ class Foo<T : Cloneable> where T : Comparable { fun <U : Cloneable> foo(u: U): U where U: Comparable { - fun <T: Any> bar() where T: U {} + fun <T: Any> bar() where T: U {} return u } diff --git a/compiler/testData/diagnostics/tests/typealias/kt14641.kt b/compiler/testData/diagnostics/tests/typealias/kt14641.kt index 19cce4033ae..cc95788fb9e 100644 --- a/compiler/testData/diagnostics/tests/typealias/kt14641.kt +++ b/compiler/testData/diagnostics/tests/typealias/kt14641.kt @@ -7,5 +7,5 @@ class A { fun f() { val a = A() - a.BAlias + a.BAlias } \ No newline at end of file diff --git a/compiler/testData/diagnostics/tests/varargs/NullableTypeForVarargArgument.kt b/compiler/testData/diagnostics/tests/varargs/NullableTypeForVarargArgument.kt index 5e7c55d1075..0f28a885684 100644 --- a/compiler/testData/diagnostics/tests/varargs/NullableTypeForVarargArgument.kt +++ b/compiler/testData/diagnostics/tests/varargs/NullableTypeForVarargArgument.kt @@ -30,9 +30,9 @@ fun baz(s: String) {} fun getArr(): Array? = null fun f() { - A().foo(1, *args) - bar(2, *args) - baz(*args) + A().foo(1, *args) + bar(2, *args) + baz(*args) } fun g(args: Array?) { diff --git a/compiler/testData/diagnostics/tests/varargs/assignNonConstSingleArrayElementAsVarargInAnnotation.kt b/compiler/testData/diagnostics/tests/varargs/assignNonConstSingleArrayElementAsVarargInAnnotation.kt index 9af27d5e84b..07d6b5ad40e 100644 --- a/compiler/testData/diagnostics/tests/varargs/assignNonConstSingleArrayElementAsVarargInAnnotation.kt +++ b/compiler/testData/diagnostics/tests/varargs/assignNonConstSingleArrayElementAsVarargInAnnotation.kt @@ -19,7 +19,7 @@ fun foo3() {} @Anno(value = [nonConstLong()]) fun foo4() {} -@Anno(value = *nonConstArray) +@Anno(value = *nonConstArray) fun bar1() {} @Anno(*nonConstArray) diff --git a/compiler/testData/diagnostics/tests/varargs/assignNonConstSingleArrayElementAsVarargInAnnotationError.kt b/compiler/testData/diagnostics/tests/varargs/assignNonConstSingleArrayElementAsVarargInAnnotationError.kt index 87efd2baa86..8ebd09ff23b 100644 --- a/compiler/testData/diagnostics/tests/varargs/assignNonConstSingleArrayElementAsVarargInAnnotationError.kt +++ b/compiler/testData/diagnostics/tests/varargs/assignNonConstSingleArrayElementAsVarargInAnnotationError.kt @@ -19,7 +19,7 @@ fun foo3() {} @Anno(value = [nonConstLong()]) fun foo4() {} -@Anno(value = *nonConstArray) +@Anno(value = *nonConstArray) fun bar1() {} @Anno(*nonConstArray) diff --git a/compiler/testData/diagnostics/tests/varargs/assigningSingleElementsInNamedFormFunDeprecation_after.kt b/compiler/testData/diagnostics/tests/varargs/assigningSingleElementsInNamedFormFunDeprecation_after.kt index 2144350eca1..ec508182b04 100644 --- a/compiler/testData/diagnostics/tests/varargs/assigningSingleElementsInNamedFormFunDeprecation_after.kt +++ b/compiler/testData/diagnostics/tests/varargs/assigningSingleElementsInNamedFormFunDeprecation_after.kt @@ -8,9 +8,9 @@ open class Cls(vararg p: Long) fun test(i: IntArray) { foo(s = 1) - foo(s = i) + foo(s = i) foo(s = *i) - foo(s = intArrayOf(1)) + foo(s = intArrayOf(1)) foo(s = *intArrayOf(1)) foo(1) diff --git a/compiler/testData/diagnostics/tests/varargs/assigningSingleElementsInNamedFormFunDeprecation_before.kt b/compiler/testData/diagnostics/tests/varargs/assigningSingleElementsInNamedFormFunDeprecation_before.kt index 3ec91aa8778..7c06def21f5 100644 --- a/compiler/testData/diagnostics/tests/varargs/assigningSingleElementsInNamedFormFunDeprecation_before.kt +++ b/compiler/testData/diagnostics/tests/varargs/assigningSingleElementsInNamedFormFunDeprecation_before.kt @@ -8,9 +8,9 @@ open class Cls(vararg p: Long) fun test(i: IntArray) { foo(s = 1) - foo(s = i) + foo(s = i) foo(s = *i) - foo(s = intArrayOf(1)) + foo(s = intArrayOf(1)) foo(s = *intArrayOf(1)) foo(1) diff --git a/compiler/testData/diagnostics/tests/when/When.kt b/compiler/testData/diagnostics/tests/when/When.kt index 177fcaa3804..67d028da910 100644 --- a/compiler/testData/diagnostics/tests/when/When.kt +++ b/compiler/testData/diagnostics/tests/when/When.kt @@ -28,7 +28,7 @@ fun test() { when (x) { s -> 1 - "" -> 1 + "" -> 1 x -> 1 1 -> 1 } diff --git a/compiler/testData/diagnostics/tests/when/withSubjectVariable/unsupportedVariableDeclarationsInWhenSubject.kt b/compiler/testData/diagnostics/tests/when/withSubjectVariable/unsupportedVariableDeclarationsInWhenSubject.kt index 21c8ca8bbf5..0fc506ca558 100644 --- a/compiler/testData/diagnostics/tests/when/withSubjectVariable/unsupportedVariableDeclarationsInWhenSubject.kt +++ b/compiler/testData/diagnostics/tests/when/withSubjectVariable/unsupportedVariableDeclarationsInWhenSubject.kt @@ -13,7 +13,7 @@ fun testSimpleValInWhenSubject() { fun testValWithoutInitializerWhenSubject() { when (val y: Any) { - is String -> y.length + is String -> y.length } } diff --git a/compiler/testData/diagnostics/testsWithJsStdLib/dynamicTypes/dynamicCastTarget.kt b/compiler/testData/diagnostics/testsWithJsStdLib/dynamicTypes/dynamicCastTarget.kt index f568074361a..ba786a14249 100644 --- a/compiler/testData/diagnostics/testsWithJsStdLib/dynamicTypes/dynamicCastTarget.kt +++ b/compiler/testData/diagnostics/testsWithJsStdLib/dynamicTypes/dynamicCastTarget.kt @@ -15,9 +15,9 @@ fun test(d: Any, dl: Collection) { when (d) { is dynamic -> {} - is dynamic? -> {} + is dynamic? -> {} !is dynamic -> {} - !is dynamic? -> {} + !is dynamic? -> {} } dl as List diff --git a/compiler/testData/diagnostics/testsWithJsStdLib/jsCode/argumentIsLiteral.kt b/compiler/testData/diagnostics/testsWithJsStdLib/jsCode/argumentIsLiteral.kt index 0a93b0e54c1..a66646c4d9c 100644 --- a/compiler/testData/diagnostics/testsWithJsStdLib/jsCode/argumentIsLiteral.kt +++ b/compiler/testData/diagnostics/testsWithJsStdLib/jsCode/argumentIsLiteral.kt @@ -9,7 +9,7 @@ fun test() { js((b)) js(("c")) js(3) - js(3 + 2) + js(3 + 2) js(1.0f) js(true) js("$a") diff --git a/compiler/testData/diagnostics/testsWithStdLib/annotations/annotationParameterMustBeConstant/array.kt b/compiler/testData/diagnostics/testsWithStdLib/annotations/annotationParameterMustBeConstant/array.kt index 98c74373c3a..8dca3f86c86 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/annotations/annotationParameterMustBeConstant/array.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/annotations/annotationParameterMustBeConstant/array.kt @@ -6,7 +6,7 @@ annotation class Ann(val i: IntArray) @Ann(intArrayOf(i2)) @Ann(intArrayOf(i3)) @Ann(intArrayOf(i, i2, i3)) -@Ann(intArrayOf(intArrayOf(i, i2, i3))) +@Ann(intArrayOf(intArrayOf(i, i2, i3))) class Test var i = 1 diff --git a/compiler/testData/diagnostics/testsWithStdLib/annotations/explicitMetadata.kt b/compiler/testData/diagnostics/testsWithStdLib/annotations/explicitMetadata.kt index f810078dfd2..9e4899ad988 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/annotations/explicitMetadata.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/annotations/explicitMetadata.kt @@ -4,6 +4,6 @@ class A @Metadata(extraString = "_") annotation class B(val m: Metadata) -@Metadata(extraInt = 0) +@Metadata(extraInt = 0) @B(Metadata()) fun f() {} diff --git a/compiler/testData/diagnostics/testsWithStdLib/annotations/jvmStatic/interfaceCompanion_LL13_16.kt b/compiler/testData/diagnostics/testsWithStdLib/annotations/jvmStatic/interfaceCompanion_LL13_16.kt index c19161af4a5..15b17fc94ef 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/annotations/jvmStatic/interfaceCompanion_LL13_16.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/annotations/jvmStatic/interfaceCompanion_LL13_16.kt @@ -6,36 +6,36 @@ interface B { } - @JvmStatic private fun a2() { + @JvmStatic private fun a2() { } - @JvmStatic protected fun a3() { + @JvmStatic protected fun a3() { } - @JvmStatic internal fun a4() { + @JvmStatic internal fun a4() { } @JvmStatic var foo = 1 - @JvmStatic + @JvmStatic var foo1 = 1 protected set - @JvmStatic + @JvmStatic var foo2 = 1 private set - @JvmStatic + @JvmStatic private var foo3 = 1 - @JvmStatic + @JvmStatic protected var foo4 = 1 - @JvmStatic + @JvmStatic protected var foo5 = 1 @JvmStatic @@ -48,7 +48,7 @@ interface B { @JvmStatic public set public var foo9 = 1 - @JvmStatic private set + @JvmStatic private set } diff --git a/compiler/testData/diagnostics/testsWithStdLib/coroutines/lambdaExpectedType.kt b/compiler/testData/diagnostics/testsWithStdLib/coroutines/lambdaExpectedType.kt index a058c970516..41d193eb683 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/coroutines/lambdaExpectedType.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/coroutines/lambdaExpectedType.kt @@ -43,7 +43,7 @@ fun foo() { val s: String = manyArgumentsBuilder({}, { "" }) { 1 } manyArgumentsBuilder({}, { "" }, { 1 }) - manyArgumentsBuilder({}, { 1 }, { 2 }) + manyArgumentsBuilder({}, { 1 }, { 2 }) severalParamsInLambda { x, y -> x checkType { _() } diff --git a/compiler/testData/diagnostics/testsWithStdLib/native/trait.kt b/compiler/testData/diagnostics/testsWithStdLib/native/trait.kt index d0c3622c48e..608f7ccb47e 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/native/trait.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/native/trait.kt @@ -2,7 +2,7 @@ import kotlin.jvm.* interface Tr { external fun foo() - external fun bar() {} + external fun bar() {} companion object { external fun foo() diff --git a/compiler/testData/diagnostics/testsWithStdLib/reified/reifiedNothingSubstitution.kt b/compiler/testData/diagnostics/testsWithStdLib/reified/reifiedNothingSubstitution.kt index be4b0fbc813..a52ba8b27fe 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/reified/reifiedNothingSubstitution.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/reified/reifiedNothingSubstitution.kt @@ -6,7 +6,7 @@ inline fun foo(block: () -> T): String = block().toString() inline fun javaClass(): Class = T::class.java fun box() { - val a = arrayOf(null!!) + val a = arrayOf(null!!) val b = Array<Nothing?>(5) { null!! } val c = foo() { null!! } val d = foo { null!! } diff --git a/compiler/testData/diagnostics/testsWithUnsignedTypes/conversions/signedToUnsignedConversionWithExpectedType.kt b/compiler/testData/diagnostics/testsWithUnsignedTypes/conversions/signedToUnsignedConversionWithExpectedType.kt index 0bf938b9b4b..de61b569c7d 100644 --- a/compiler/testData/diagnostics/testsWithUnsignedTypes/conversions/signedToUnsignedConversionWithExpectedType.kt +++ b/compiler/testData/diagnostics/testsWithUnsignedTypes/conversions/signedToUnsignedConversionWithExpectedType.kt @@ -33,7 +33,7 @@ fun test() { takeUInt(Int.MAX_VALUE * 2) takeUInt(4294967294) - takeUBytes(1, 2, 255, 256, 0, -1, 40 + 2) + takeUBytes(1, 2, 255, 256, 0, -1, 40 + 2) takeUInt(1.myPlus(2)) diff --git a/compiler/testData/javac/diagnostics/tests/imports/PackagePrivateAndPublicNested.kt b/compiler/testData/javac/diagnostics/tests/imports/PackagePrivateAndPublicNested.kt index d999c260541..664392a7bb0 100644 --- a/compiler/testData/javac/diagnostics/tests/imports/PackagePrivateAndPublicNested.kt +++ b/compiler/testData/javac/diagnostics/tests/imports/PackagePrivateAndPublicNested.kt @@ -11,7 +11,7 @@ package a import p.Foo import p.Foo.Nested -class Bar : Foo() { +class Bar : Foo() { protected fun foo(): Nested? = null } diff --git a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/1.1.kt b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/1.1.kt index 7a9e8003559..5d805129134 100644 --- a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/1.1.kt +++ b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/1.1.kt @@ -48,7 +48,7 @@ val value_12 = .8____88888888888888888888888888888 val value_13 = 0_0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000_0eF // TESTCASE NUMBER: 14 -val value_14 = 0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_e-f +val value_14 = 0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_0_e-f // TESTCASE NUMBER: 15 val value_15 = .000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e+ diff --git a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/1.2.kt b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/1.2.kt index 9df5061cab7..364f7abef9f 100644 --- a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/1.2.kt +++ b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/1.2.kt @@ -27,7 +27,7 @@ val value_5 = 0_00e1_ val value_6 = .0_0__0___0E0_______________ // TESTCASE NUMBER: 7 -val value_7 = 0_1e+100_____f +val value_7 = 0_1e+100_____f // TESTCASE NUMBER: 8 val value_8 = .0_0E-0001___ @@ -39,7 +39,7 @@ val value_9 = 0___0__0e4___ val value_10 = 0_00_0e99_f // TESTCASE NUMBER: 11 -val value_11 = .0_5E-93_______F +val value_11 = .0_5E-93_______F // TESTCASE NUMBER: 12 val value_12 = .8____8888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888_____8888888888888888888e+5_f diff --git a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.1.kt b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.1.kt index a03af350224..6b9a5e1a891 100644 --- a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.1.kt +++ b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.1.kt @@ -24,7 +24,7 @@ val value_4 = 0__0.0_____e0f val value_5 = 9_______9______9_____9____9___9__9_9.0___E-1 // TESTCASE NUMBER: 6 -val value_6 = 0_0_0_0_0_0_0_0_0_0.12345678___e+90F +val value_6 = 0_0_0_0_0_0_0_0_0_0.12345678___e+90F // TESTCASE NUMBER: 7 val value_7 = 1_2_3_4_5_6_7_8_9.2_3_4_5_6_7_8_9_e-0 @@ -39,7 +39,7 @@ val value_9 = 5.6_0_E+05F val value_10 = 6_54.76_5__e-4 // TESTCASE NUMBER: 11 -val value_11 = 9_____________87654321.0__e-9_8765432_____________1F +val value_11 = 9_____________87654321.0__e-9_8765432_____________1F // TESTCASE NUMBER: 12 val value_12 = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000___0.000000000000000000000000_e000000000000000000000000000000000000000000000000000000000000000_0F @@ -48,4 +48,4 @@ val value_12 = 0000000000000000000000000000000000000000000 val value_13 = 0_000000000000000000000000000000000000000000000000000000000000000000000000000000000000000.0____E-0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 // TESTCASE NUMBER: 14 -val value_14 = 9999999999999999999999999999999999999999999_______________999999999999999999999999999999999999999999999.33333333333333333333333333333333333333333333333_333333333333333333333333333333333333333_e3_3f +val value_14 = 9999999999999999999999999999999999999999999_______________999999999999999999999999999999999999999999999.33333333333333333333333333333333333333333333333_333333333333333333333333333333333333333_e3_3f diff --git a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.2.kt b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.2.kt index 30ac508143a..ff6a35af7ef 100644 --- a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.2.kt +++ b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.2.kt @@ -27,10 +27,10 @@ val value_5 = 1E-_2F val value_6 = 3e+_0f // TESTCASE NUMBER: 7 -val value_7 = 5E_-0 +val value_7 = 5E_-0 // TESTCASE NUMBER: 8 -val value_8 = 5e_-0F +val value_8 = 5e_-0F // TESTCASE NUMBER: 9 val value_9 = 5e_00000000 @@ -39,7 +39,7 @@ val value_9 = 5e_00000000 val value_10 = 0.0_0e_1_0f // TESTCASE NUMBER: 11 -val value_11 = 0.0_0E____-0__0_0F +val value_11 = 0.0_0E____-0__0_0F // TESTCASE NUMBER: 12 val value_12 = .0_0E__0_0 @@ -63,16 +63,16 @@ val value_17 = 666_666.0__________________________________ val value_18 = 8888888_8.000e_____0f // TESTCASE NUMBER: 19 -val value_19 = 9_______9______9_____9____9___9__9_9.0E__-1 +val value_19 = 9_______9______9_____9____9___9__9_9.0E__-1 // TESTCASE NUMBER: 20 -val value_20 = 0_0_0_0_0_0_0_0_0_0.12345678e+__90F +val value_20 = 0_0_0_0_0_0_0_0_0_0.12345678e+__90F // TESTCASE NUMBER: 21 -val value_21 = 1_2_3_4_5_6_7_8_9.2_3_4_5_6_7_8_9e_-_0 +val value_21 = 1_2_3_4_5_6_7_8_9.2_3_4_5_6_7_8_9e_-_0 // TESTCASE NUMBER: 22 -val value_22 = .345______________6e_____7_______8f +val value_22 = .345______________6e_____7_______8f // TESTCASE NUMBER: 23 val value_23 = .45_6E_7f @@ -81,10 +81,10 @@ val value_23 = .45_6E_7f val value_24 = 6_54.765e-_4 // TESTCASE NUMBER: 25 -val value_25 = 7_6543.8E____7654_3 +val value_25 = 7_6543.8E____7654_3 // TESTCASE NUMBER: 26 -val value_26 = .9E+_______0_____________8765432f +val value_26 = .9E+_______0_____________8765432f // TESTCASE NUMBER: 27 val value_27 = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000___0.000000000000000000000000e_000000000000000000000000000000000000000000000000000000000000000_0F @@ -93,4 +93,4 @@ val value_27 = 0000000000000000000000000000000000000000000 val value_28 = 0_000000000000000000000000000000000000000000000000000000000000000000000000000000000000000.0E-_0___000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 // TESTCASE NUMBER: 29 -val value_29 = 9999999999999999999999999999999999999999999_______________999999999999999999999999999999999999999999999.33333333333333333333333333333333333333333333333_333333333333333333333333333333333333333e___3_3f +val value_29 = 9999999999999999999999999999999999999999999_______________999999999999999999999999999999999999999999999.33333333333333333333333333333333333333333333333_333333333333333333333333333333333333333e___3_3f diff --git a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.3.kt b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.3.kt index b2ebf30b068..8412a5c4e73 100644 --- a/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.3.kt +++ b/compiler/tests-spec/testData/diagnostics/linked/constant-literals/real-literals/p-4/neg/2.3.kt @@ -21,16 +21,16 @@ val value_3 = 1_E-_2F val value_4 = 3_e+_0f // TESTCASE NUMBER: 5 -val value_5 = 5_E_-0 +val value_5 = 5_E_-0 // TESTCASE NUMBER: 6 -val value_6 = 5_e_-0F +val value_6 = 5_e_-0F // TESTCASE NUMBER: 7 val value_7 = 5_e_00000000 // TESTCASE NUMBER: 8 -val value_8 = 0.0_0___E____-0__0_0F +val value_8 = 0.0_0___E____-0__0_0F // TESTCASE NUMBER: 9 val value_9 = 0__0.0_____e___0f @@ -48,19 +48,19 @@ val value_12 = 33__3.0_e_10__0 val value_13 = .0_E_0______00F // TESTCASE NUMBER: 14 -val value_14 = 5_________555_________5.0____e____-____9 +val value_14 = 5_________555_________5.0____e____-____9 // TESTCASE NUMBER: 15 val value_15 = 666_666.0__________________________________________________1_E+_2___________________________________________________________________0F // TESTCASE NUMBER: 16 -val value_16 = 9_______9______9_____9____9___9__9_9.0___E__-1 +val value_16 = 9_______9______9_____9____9___9__9_9.0___E__-1 // TESTCASE NUMBER: 17 -val value_17 = 0_0_0_0_0_0_0_0_0_0.12345678___e+__90F +val value_17 = 0_0_0_0_0_0_0_0_0_0.12345678___e+__90F // TESTCASE NUMBER: 18 -val value_18 = 1_2_3_4_5_6_7_8_9.2_3_4_5_6_7_8_9_e_-_0 +val value_18 = 1_2_3_4_5_6_7_8_9.2_3_4_5_6_7_8_9_e_-_0 // TESTCASE NUMBER: 19 val value_19 = .45_6_E_7f @@ -72,10 +72,10 @@ val value_20 = 456.5__e_0_6 val value_21 = 6_54.76_5_e-_4 // TESTCASE NUMBER: 22 -val value_22 = 7_6543.8____E____7654_3 +val value_22 = 7_6543.8____E____7654_3 // TESTCASE NUMBER: 23 -val value_23 = 9_____________87654321.0__e__-9_8765432_____________1F +val value_23 = 9_____________87654321.0__e__-9_8765432_____________1F // TESTCASE NUMBER: 24 val value_24 = 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000___0.000000000000000000000000_e_000000000000000000000000000000000000000000000000000000000000000_0F @@ -84,4 +84,4 @@ val value_24 = 0000000000000000000000000000000000000000000 val value_25 = 0_000000000000000000000000000000000000000000000000000000000000000000000000000000000000000.0_E-_0___000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 // TESTCASE NUMBER: 26 -val value_26 = 9999999999999999999999999999999999999999999_______________999999999999999999999999999999999999999999999.33333333333333333333333333333333333333333333333_333333333333333333333333333333333333333_e_3_3f +val value_26 = 9999999999999999999999999999999999999999999_______________999999999999999999999999999999999999999999999.33333333333333333333333333333333333333333333333_333333333333333333333333333333333333333_e_3_3f diff --git a/compiler/tests-spec/testData/diagnostics/linked/when-expression/p-7/neg/3.2.kt b/compiler/tests-spec/testData/diagnostics/linked/when-expression/p-7/neg/3.2.kt index 4aecb70f5d8..56b179ead2e 100644 --- a/compiler/tests-spec/testData/diagnostics/linked/when-expression/p-7/neg/3.2.kt +++ b/compiler/tests-spec/testData/diagnostics/linked/when-expression/p-7/neg/3.2.kt @@ -14,9 +14,9 @@ // TESTCASE NUMBER: 1 fun case_1(value_1: Int, value_2: _EmptyClass, value_3: Int, value_4: Any): String { when (value_1) { - in value_2 -> return "" - in value_3 -> return "" - in value_4 -> return "" + in value_2 -> return "" + in value_3 -> return "" + in value_4 -> return "" } return "" diff --git a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/neg/7.kt b/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/neg/7.kt index da8347ea28f..b5291aa5550 100644 --- a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/neg/7.kt +++ b/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/neg/7.kt @@ -246,7 +246,7 @@ fun case_4(value_1: Any?) { value_1?.toByte() case_4_2(value_1) value_1.toByte() - case_4_3(value_1) + case_4_3(value_1) value_1.inv() } @@ -340,28 +340,28 @@ fun case_8(value_1: Any?) { value_1?.toByte() if (case_8_2(value_1)) { value_1.toByte() - if (case_8_3(value_1)) value_1.inv() + if (case_8_3(value_1)) value_1.inv() } } if (!case_8_4(value_1)) { value_1?.toByte() if (!case_8_5(value_1)) { value_1.toByte() - if (!case_8_6(value_1)) value_1.inv() + if (!case_8_6(value_1)) value_1.inv() } } if (case_8_7(value_1) == null) { value_1?.toByte() if (case_8_8(value_1) != null) { value_1.toByte() - if (case_8_9(value_1) != null) value_1.inv() + if (case_8_9(value_1) != null) value_1.inv() } } if (case_8_10(value_1) != null) { value_1?.toByte() if (case_8_11(value_1) == null) { value_1.toByte() - if (case_8_12(value_1) == null) value_1.inv() + if (case_8_12(value_1) == null) value_1.inv() } } } diff --git a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/neg/8.kt b/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/neg/8.kt index 6b253097a6c..476bfd483aa 100644 --- a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/neg/8.kt +++ b/compiler/tests-spec/testData/diagnostics/notLinked/contracts/analysis/smartcasts/neg/8.kt @@ -103,7 +103,7 @@ fun case_4(value_1: Number, value_2: (() -> Unit)?) { } else if (contracts.case_4(value_1, value_2) == false) { println(value_2) } else if (contracts.case_4(value_1, value_2) == null) { - value_2() + value_2() } } diff --git a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/declarations/contractBuilder/common/neg/5.kt b/compiler/tests-spec/testData/diagnostics/notLinked/contracts/declarations/contractBuilder/common/neg/5.kt index 55425c12898..931a297910b 100644 --- a/compiler/tests-spec/testData/diagnostics/notLinked/contracts/declarations/contractBuilder/common/neg/5.kt +++ b/compiler/tests-spec/testData/diagnostics/notLinked/contracts/declarations/contractBuilder/common/neg/5.kt @@ -13,7 +13,7 @@ import kotlin.contracts.* // TESTCASE NUMBER: 1 fun case_1(): Boolean { - contract { returns(true) implies (-10) } + contract { returns(true) implies (-10) } return true } @@ -25,7 +25,7 @@ fun case_2(): Boolean { // TESTCASE NUMBER: 3 fun case_3(): Boolean { - contract { returns(false) implies ("..." + "$value_1") } + contract { returns(false) implies ("..." + "$value_1") } return true } @@ -41,12 +41,12 @@ fun case_4(): Boolean? { // TESTCASE NUMBER: 5 fun case_5(): Boolean? { - contract { returns(null) implies listOf(0) } + contract { returns(null) implies listOf(0) } return null } // TESTCASE NUMBER: 6 fun case_6(value_1: Boolean): Boolean? { - contract { returns(null) implies contract { returns(null) implies (!value_1) } } + contract { returns(null) implies contract { returns(null) implies (!value_1) } } return null } diff --git a/plugins/sam-with-receiver/sam-with-receiver-cli/testData/diagnostics/singleParameter.kt b/plugins/sam-with-receiver/sam-with-receiver-cli/testData/diagnostics/singleParameter.kt index 151f887f87f..cb7bc7aac4b 100644 --- a/plugins/sam-with-receiver/sam-with-receiver-cli/testData/diagnostics/singleParameter.kt +++ b/plugins/sam-with-receiver/sam-with-receiver-cli/testData/diagnostics/singleParameter.kt @@ -10,7 +10,7 @@ public interface Sam { annotation class SamWithReceiver fun test() { - Sam { a -> + Sam { a -> System.out.println(a) }