diff --git a/compiler/testData/asJava/lightClassStructure/Declared.kt b/compiler/testData/asJava/lightClassStructure/Declared.kt
index f8dbe82eafa..e09d095bfe4 100644
--- a/compiler/testData/asJava/lightClassStructure/Declared.kt
+++ b/compiler/testData/asJava/lightClassStructure/Declared.kt
@@ -23,7 +23,7 @@ final class Final
// Special
annotation class Annotation
enum class Enum
-trait Trait
+interface Trait
// Deprecation
deprecated("") class Deprecated
diff --git a/compiler/testData/asJava/lightClassStructure/DeclaredWithGenerics.kt b/compiler/testData/asJava/lightClassStructure/DeclaredWithGenerics.kt
index 70e2c5e47e5..440a2203f1e 100644
--- a/compiler/testData/asJava/lightClassStructure/DeclaredWithGenerics.kt
+++ b/compiler/testData/asJava/lightClassStructure/DeclaredWithGenerics.kt
@@ -7,5 +7,5 @@ class Generic2
class Generic2WithBounds where A: Bound1, A: Bound2, B: Generic1
class Bound1
-trait Bound2
+interface Bound2
diff --git a/compiler/testData/asJava/lightClasses/delegation/Function.kt b/compiler/testData/asJava/lightClasses/delegation/Function.kt
index 9fda4a47c45..2b0a72c3c32 100644
--- a/compiler/testData/asJava/lightClasses/delegation/Function.kt
+++ b/compiler/testData/asJava/lightClasses/delegation/Function.kt
@@ -1,6 +1,6 @@
// Derived
-trait Base {
+interface Base {
fun baz(s: String): String
}
diff --git a/compiler/testData/asJava/lightClasses/delegation/Property.kt b/compiler/testData/asJava/lightClasses/delegation/Property.kt
index ce590bfa050..7b2c815ace1 100644
--- a/compiler/testData/asJava/lightClasses/delegation/Property.kt
+++ b/compiler/testData/asJava/lightClasses/delegation/Property.kt
@@ -1,6 +1,6 @@
// Derived
-trait Base {
+interface Base {
val boo: String
}
diff --git a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Generic.kt b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Generic.kt
index 2541b473c8e..a1b5772cb8b 100644
--- a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Generic.kt
+++ b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Generic.kt
@@ -1,6 +1,6 @@
// Generic
-trait Generic {
+interface Generic {
fun a(n: N): N
fun b(nn: NN): NN
diff --git a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/IntOverridesAny.kt b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/IntOverridesAny.kt
index 274a682a4f6..0bc3e928ac2 100644
--- a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/IntOverridesAny.kt
+++ b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/IntOverridesAny.kt
@@ -1,6 +1,6 @@
// C
-trait Tr {
+interface Tr {
fun foo(): Any
val v: Any
}
diff --git a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/OverrideAnyWithUnit.kt b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/OverrideAnyWithUnit.kt
index 1efb58ec710..9915f6225bd 100644
--- a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/OverrideAnyWithUnit.kt
+++ b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/OverrideAnyWithUnit.kt
@@ -1,6 +1,6 @@
// C
-trait Base {
+interface Base {
fun foo(): Any
}
diff --git a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Primitives.kt b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Primitives.kt
index 7efecda0ad5..b586c4344c1 100644
--- a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Primitives.kt
+++ b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Primitives.kt
@@ -1,6 +1,6 @@
// Primitives
-trait Primitives {
+interface Primitives {
fun int(x: Int): Int
val nullableBool: Boolean?
diff --git a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/PrivateInTrait.kt b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/PrivateInTrait.kt
index f15c852a545..3b69e0a805c 100644
--- a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/PrivateInTrait.kt
+++ b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/PrivateInTrait.kt
@@ -1,6 +1,6 @@
// PrivateInTrait
-trait PrivateInTrait {
+interface PrivateInTrait {
private var nn: String
get() = ""
set(value) {}
diff --git a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Trait.kt b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Trait.kt
index ebced47d04e..11d7f619b95 100644
--- a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Trait.kt
+++ b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/Trait.kt
@@ -3,7 +3,7 @@
import org.jetbrains.annotations.NotNull
import org.jetbrains.annotations.Nullable
-trait Trait {
+interface Trait {
fun notNull(a: String): String
fun nullable(a: String?): String?
diff --git a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/TraitClassObjectField.kt b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/TraitClassObjectField.kt
index 73598d0f805..18550ad7fc4 100644
--- a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/TraitClassObjectField.kt
+++ b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/TraitClassObjectField.kt
@@ -1,6 +1,6 @@
// TraitClassObjectField
-trait TraitClassObjectField {
+interface TraitClassObjectField {
companion object {
val x: String? = ""
private val y: String? = ""
diff --git a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/UnitAsGenericArgument.kt b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/UnitAsGenericArgument.kt
index be4e460f616..a4ecf3d1916 100644
--- a/compiler/testData/asJava/lightClasses/nullabilityAnnotations/UnitAsGenericArgument.kt
+++ b/compiler/testData/asJava/lightClasses/nullabilityAnnotations/UnitAsGenericArgument.kt
@@ -1,6 +1,6 @@
// C
-trait Base {
+interface Base {
fun foo(t: T): T
}
diff --git a/compiler/testData/cfg-variables/basic/VariablesInitialization.instructions b/compiler/testData/cfg-variables/basic/VariablesInitialization.instructions
index 28c356a8d57..8aa81131cf1 100644
--- a/compiler/testData/cfg-variables/basic/VariablesInitialization.instructions
+++ b/compiler/testData/cfg-variables/basic/VariablesInitialization.instructions
@@ -51,7 +51,7 @@ sink:
INIT: in: {foo=ID} out: {foo=ID} USE: in: {} out: {}
=====================
== Foo ==
-trait Foo {
+interface Foo {
var c: Int
}
---------------------
diff --git a/compiler/testData/cfg-variables/basic/VariablesInitialization.kt b/compiler/testData/cfg-variables/basic/VariablesInitialization.kt
index ae78a8a15e1..58f7e678bef 100644
--- a/compiler/testData/cfg-variables/basic/VariablesInitialization.kt
+++ b/compiler/testData/cfg-variables/basic/VariablesInitialization.kt
@@ -11,6 +11,6 @@ fun bar(foo: Foo) {
42
}
-trait Foo {
+interface Foo {
var c: Int
}
\ No newline at end of file
diff --git a/compiler/testData/cfg-variables/basic/VariablesInitialization.values b/compiler/testData/cfg-variables/basic/VariablesInitialization.values
index 9401bee010c..9a9d3f560be 100644
--- a/compiler/testData/cfg-variables/basic/VariablesInitialization.values
+++ b/compiler/testData/cfg-variables/basic/VariablesInitialization.values
@@ -28,7 +28,7 @@ foo : {<: Foo} NEW: r(foo) ->
{ foo.c foo.c = 2 42 } : * COPY
=====================
== Foo ==
-trait Foo {
+interface Foo {
var c: Int
}
---------------------
diff --git a/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.instructions b/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.instructions
index b2917e4afd8..53d4756dcaf 100644
--- a/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.instructions
+++ b/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.instructions
@@ -1,5 +1,5 @@
== T ==
-trait T
+interface T
---------------------
L0:
1
diff --git a/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.kt b/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.kt
index 8071281842b..36d898f091b 100644
--- a/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.kt
+++ b/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.kt
@@ -1,4 +1,4 @@
-trait T
+interface T
class A(a: Int, b: Int): T
diff --git a/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.values b/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.values
index c5f4dbea26c..c6d2ab9a9d1 100644
--- a/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.values
+++ b/compiler/testData/cfg/declarations/classesAndObjects/delegationByExpression.values
@@ -1,5 +1,5 @@
== T ==
-trait T
+interface T
---------------------
=====================
== A ==
diff --git a/compiler/testData/cfg/declarations/local/ObjectExpression.instructions b/compiler/testData/cfg/declarations/local/ObjectExpression.instructions
index 33e977e7794..3bb05196aa5 100644
--- a/compiler/testData/cfg/declarations/local/ObjectExpression.instructions
+++ b/compiler/testData/cfg/declarations/local/ObjectExpression.instructions
@@ -1,5 +1,5 @@
== A ==
-trait A {
+interface A {
fun foo() : Int
}
---------------------
diff --git a/compiler/testData/cfg/declarations/local/ObjectExpression.kt b/compiler/testData/cfg/declarations/local/ObjectExpression.kt
index cf5ba96f594..cac81104548 100644
--- a/compiler/testData/cfg/declarations/local/ObjectExpression.kt
+++ b/compiler/testData/cfg/declarations/local/ObjectExpression.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo() : Int
}
diff --git a/compiler/testData/cfg/declarations/local/ObjectExpression.values b/compiler/testData/cfg/declarations/local/ObjectExpression.values
index 9f3d26b4b75..d9e98bf93d8 100644
--- a/compiler/testData/cfg/declarations/local/ObjectExpression.values
+++ b/compiler/testData/cfg/declarations/local/ObjectExpression.values
@@ -1,5 +1,5 @@
== A ==
-trait A {
+interface A {
fun foo() : Int
}
---------------------
diff --git a/compiler/testData/cli/jvm/multipleTextRangesInDiagnosticsOrder.kt b/compiler/testData/cli/jvm/multipleTextRangesInDiagnosticsOrder.kt
index 7340ff8a25d..29e26a1bf18 100644
--- a/compiler/testData/cli/jvm/multipleTextRangesInDiagnosticsOrder.kt
+++ b/compiler/testData/cli/jvm/multipleTextRangesInDiagnosticsOrder.kt
@@ -1,7 +1,7 @@
-trait A {
+interface A {
public val c: Int
}
-trait B: A {
+interface B: A {
override protected private val c: Int
}
diff --git a/compiler/testData/cli/jvm/signatureClash.kt b/compiler/testData/cli/jvm/signatureClash.kt
index e7e5eafa6d1..7dbda49c9db 100644
--- a/compiler/testData/cli/jvm/signatureClash.kt
+++ b/compiler/testData/cli/jvm/signatureClash.kt
@@ -12,7 +12,7 @@ class A : B() {
fun getB(): Int = 1
val b: Int = 1
-trait Tr {
+interface Tr {
fun getTr() = 1
}
diff --git a/compiler/testData/cli/jvm/wrongAbiVersionLib/src/TraitWithDefault.kt b/compiler/testData/cli/jvm/wrongAbiVersionLib/src/TraitWithDefault.kt
index df593504f3d..4c81a02698d 100644
--- a/compiler/testData/cli/jvm/wrongAbiVersionLib/src/TraitWithDefault.kt
+++ b/compiler/testData/cli/jvm/wrongAbiVersionLib/src/TraitWithDefault.kt
@@ -1,5 +1,5 @@
package wrong
-trait TraitWithDefault {
+interface TraitWithDefault {
fun foo() = 1
}
\ No newline at end of file
diff --git a/compiler/testData/cli/warnings.kt b/compiler/testData/cli/warnings.kt
index ad276976b28..7a459c181d4 100644
--- a/compiler/testData/cli/warnings.kt
+++ b/compiler/testData/cli/warnings.kt
@@ -5,6 +5,6 @@ fun foo(p: Int??) {
}
-trait T {
+interface T {
abstract fun foo()
}
\ No newline at end of file
diff --git a/compiler/testData/codegen/box/bridges/complexMultiInheritance.kt b/compiler/testData/codegen/box/bridges/complexMultiInheritance.kt
index cce9635c317..2128aa8fab4 100644
--- a/compiler/testData/codegen/box/bridges/complexMultiInheritance.kt
+++ b/compiler/testData/codegen/box/bridges/complexMultiInheritance.kt
@@ -2,13 +2,13 @@ open class A {
open fun foo(): Any = "A"
}
-trait B : A
+interface B : A
open class C : A() {
override fun foo(): Int = 222
}
-trait D {
+interface D {
fun foo(): Number
}
diff --git a/compiler/testData/codegen/box/bridges/complexTraitImpl.kt b/compiler/testData/codegen/box/bridges/complexTraitImpl.kt
index 18f692013e5..ce91d13f080 100644
--- a/compiler/testData/codegen/box/bridges/complexTraitImpl.kt
+++ b/compiler/testData/codegen/box/bridges/complexTraitImpl.kt
@@ -5,13 +5,13 @@ abstract class A {
abstract fun foo(): List
}
-trait B {
+interface B {
fun foo(): ArrayList = ArrayList(Arrays.asList("B"))
}
open class C : A(), B
-trait D {
+interface D {
fun foo(): Collection
}
diff --git a/compiler/testData/codegen/box/bridges/delegation.kt b/compiler/testData/codegen/box/bridges/delegation.kt
index 41c3ddd3470..d0dd7aa00f0 100644
--- a/compiler/testData/codegen/box/bridges/delegation.kt
+++ b/compiler/testData/codegen/box/bridges/delegation.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(): T
}
diff --git a/compiler/testData/codegen/box/bridges/delegationProperty.kt b/compiler/testData/codegen/box/bridges/delegationProperty.kt
index 5ffd4270b87..768f010140f 100644
--- a/compiler/testData/codegen/box/bridges/delegationProperty.kt
+++ b/compiler/testData/codegen/box/bridges/delegationProperty.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
var result: T
}
diff --git a/compiler/testData/codegen/box/bridges/diamond.kt b/compiler/testData/codegen/box/bridges/diamond.kt
index 2e798707253..b1ea60973a5 100644
--- a/compiler/testData/codegen/box/bridges/diamond.kt
+++ b/compiler/testData/codegen/box/bridges/diamond.kt
@@ -1,10 +1,10 @@
-trait A {
+interface A {
fun foo(t: T, u: U) = "A"
}
-trait B : A
+interface B : A
-trait C : A
+interface C : A
class Z : B, C {
override fun foo(t: String, u: Int) = "Z"
diff --git a/compiler/testData/codegen/box/bridges/fakeCovariantOverride.kt b/compiler/testData/codegen/box/bridges/fakeCovariantOverride.kt
index bb93071f603..e62de29d55a 100644
--- a/compiler/testData/codegen/box/bridges/fakeCovariantOverride.kt
+++ b/compiler/testData/codegen/box/bridges/fakeCovariantOverride.kt
@@ -1,6 +1,6 @@
// KT-4145
-trait A {
+interface A {
fun foo(): Any
}
diff --git a/compiler/testData/codegen/box/bridges/fakeGenericContravariantOverride1.kt b/compiler/testData/codegen/box/bridges/fakeGenericContravariantOverride1.kt
index 78b90f2fe89..822954327ea 100644
--- a/compiler/testData/codegen/box/bridges/fakeGenericContravariantOverride1.kt
+++ b/compiler/testData/codegen/box/bridges/fakeGenericContravariantOverride1.kt
@@ -1,8 +1,8 @@
-trait A {
+interface A {
fun foo(t: T): String
}
-trait B {
+interface B {
fun foo(t: Int) = "B"
}
diff --git a/compiler/testData/codegen/box/bridges/fakeGenericContravariantOverride2.kt b/compiler/testData/codegen/box/bridges/fakeGenericContravariantOverride2.kt
index 2a946f96200..73a3d93682b 100644
--- a/compiler/testData/codegen/box/bridges/fakeGenericContravariantOverride2.kt
+++ b/compiler/testData/codegen/box/bridges/fakeGenericContravariantOverride2.kt
@@ -1,8 +1,8 @@
-trait A {
+interface A {
fun foo(t: T): String
}
-trait B {
+interface B {
fun foo(a: T) = "B"
}
diff --git a/compiler/testData/codegen/box/bridges/fakeGenericCovariantOverride.kt b/compiler/testData/codegen/box/bridges/fakeGenericCovariantOverride.kt
index 0225c55c686..584d1ce3da3 100644
--- a/compiler/testData/codegen/box/bridges/fakeGenericCovariantOverride.kt
+++ b/compiler/testData/codegen/box/bridges/fakeGenericCovariantOverride.kt
@@ -1,6 +1,6 @@
// KT-3985
-trait Trait {
+interface Trait {
fun f(): T
}
diff --git a/compiler/testData/codegen/box/bridges/fakeGenericCovariantOverrideWithDelegation.kt b/compiler/testData/codegen/box/bridges/fakeGenericCovariantOverrideWithDelegation.kt
index 4fa2cc018a8..e794fa46083 100644
--- a/compiler/testData/codegen/box/bridges/fakeGenericCovariantOverrideWithDelegation.kt
+++ b/compiler/testData/codegen/box/bridges/fakeGenericCovariantOverrideWithDelegation.kt
@@ -1,8 +1,8 @@
-trait A {
+interface A {
fun foo(t: T): String
}
-trait B {
+interface B {
fun foo(t: Int) = "B"
}
diff --git a/compiler/testData/codegen/box/bridges/fakeOverrideInTraitWithRequiredFromTraitImpl.kt b/compiler/testData/codegen/box/bridges/fakeOverrideInTraitWithRequiredFromTraitImpl.kt
index ba0b79cbdda..fee76a53e9c 100644
--- a/compiler/testData/codegen/box/bridges/fakeOverrideInTraitWithRequiredFromTraitImpl.kt
+++ b/compiler/testData/codegen/box/bridges/fakeOverrideInTraitWithRequiredFromTraitImpl.kt
@@ -2,11 +2,11 @@ abstract class A {
abstract fun foo(): Any
}
-trait B {
+interface B {
fun foo(): String = "B"
}
-trait C : A, B
+interface C : A, B
class D : A(), C
diff --git a/compiler/testData/codegen/box/bridges/fakeOverrideOfPropertySetterInTraitImpl.kt b/compiler/testData/codegen/box/bridges/fakeOverrideOfPropertySetterInTraitImpl.kt
index 4a6a4a9e2fa..78126d2ac93 100644
--- a/compiler/testData/codegen/box/bridges/fakeOverrideOfPropertySetterInTraitImpl.kt
+++ b/compiler/testData/codegen/box/bridges/fakeOverrideOfPropertySetterInTraitImpl.kt
@@ -1,6 +1,6 @@
var result = ""
-trait A {
+interface A {
var foo: String
get() = result
set(value) {
diff --git a/compiler/testData/codegen/box/bridges/fakeOverrideOfTraitImpl.kt b/compiler/testData/codegen/box/bridges/fakeOverrideOfTraitImpl.kt
index f8850de7c2b..1f023aad5ba 100644
--- a/compiler/testData/codegen/box/bridges/fakeOverrideOfTraitImpl.kt
+++ b/compiler/testData/codegen/box/bridges/fakeOverrideOfTraitImpl.kt
@@ -1,15 +1,15 @@
var result = ""
-trait D1 {
+interface D1 {
fun foo(): D1 {
result += "D1"
return this
}
}
-trait F2 : D1
+interface F2 : D1
-trait D3 : F2 {
+interface D3 : F2 {
override fun foo(): D3 {
result += "D3"
return this
diff --git a/compiler/testData/codegen/box/bridges/fakeOverrideWithImplementationInTrait.kt b/compiler/testData/codegen/box/bridges/fakeOverrideWithImplementationInTrait.kt
index 3f3a0750cf1..843f133922b 100644
--- a/compiler/testData/codegen/box/bridges/fakeOverrideWithImplementationInTrait.kt
+++ b/compiler/testData/codegen/box/bridges/fakeOverrideWithImplementationInTrait.kt
@@ -1,8 +1,8 @@
-trait A {
+interface A {
fun foo(): String = "A"
}
-trait B {
+interface B {
fun foo(): Any
}
diff --git a/compiler/testData/codegen/box/bridges/fakeOverrideWithSeveralSuperDeclarations.kt b/compiler/testData/codegen/box/bridges/fakeOverrideWithSeveralSuperDeclarations.kt
index 04a752cf905..461f1b25c8b 100644
--- a/compiler/testData/codegen/box/bridges/fakeOverrideWithSeveralSuperDeclarations.kt
+++ b/compiler/testData/codegen/box/bridges/fakeOverrideWithSeveralSuperDeclarations.kt
@@ -1,12 +1,12 @@
-trait D1 {
+interface D1 {
fun foo(): Any
}
-trait D2 {
+interface D2 {
fun foo(): Number
}
-trait F3 : D1, D2
+interface F3 : D1, D2
open class D4 {
fun foo(): Int = 42
diff --git a/compiler/testData/codegen/box/bridges/fakeOverrideWithSynthesizedImplementation.kt b/compiler/testData/codegen/box/bridges/fakeOverrideWithSynthesizedImplementation.kt
index a4d0a21e5f9..13b87b448a2 100644
--- a/compiler/testData/codegen/box/bridges/fakeOverrideWithSynthesizedImplementation.kt
+++ b/compiler/testData/codegen/box/bridges/fakeOverrideWithSynthesizedImplementation.kt
@@ -1,6 +1,6 @@
open data class A(val value: String)
-trait B {
+interface B {
fun component1(): Any
}
diff --git a/compiler/testData/codegen/box/bridges/kt1939.kt b/compiler/testData/codegen/box/bridges/kt1939.kt
index 81cc023ddaa..ff7e345fdde 100644
--- a/compiler/testData/codegen/box/bridges/kt1939.kt
+++ b/compiler/testData/codegen/box/bridges/kt1939.kt
@@ -2,7 +2,7 @@ abstract class Foo {
fun hello(id: T) = "Hi $id"
}
-trait Tr {
+interface Tr {
fun hello(s : String)
}
diff --git a/compiler/testData/codegen/box/bridges/kt2833.kt b/compiler/testData/codegen/box/bridges/kt2833.kt
index c5d90cbede8..50a2989d904 100644
--- a/compiler/testData/codegen/box/bridges/kt2833.kt
+++ b/compiler/testData/codegen/box/bridges/kt2833.kt
@@ -1,10 +1,10 @@
package test
-public trait FunDependencyEdge {
+public interface FunDependencyEdge {
val from: FunctionNode
}
-public trait FunctionNode
+public interface FunctionNode
public class FunctionNodeImpl : FunctionNode
diff --git a/compiler/testData/codegen/box/bridges/kt2920.kt b/compiler/testData/codegen/box/bridges/kt2920.kt
index 07802cbaad3..0f71953ba12 100644
--- a/compiler/testData/codegen/box/bridges/kt2920.kt
+++ b/compiler/testData/codegen/box/bridges/kt2920.kt
@@ -1,4 +1,4 @@
-trait Tr {
+interface Tr {
val v: T
}
diff --git a/compiler/testData/codegen/box/bridges/kt318.kt b/compiler/testData/codegen/box/bridges/kt318.kt
index c1929b1d81a..f454d01992d 100644
--- a/compiler/testData/codegen/box/bridges/kt318.kt
+++ b/compiler/testData/codegen/box/bridges/kt318.kt
@@ -1,9 +1,9 @@
var result = ""
-trait Base
+interface Base
open class Child : Base
-trait A {
+interface A {
fun foo(a : E) {
result += "A"
}
diff --git a/compiler/testData/codegen/box/bridges/methodFromTrait.kt b/compiler/testData/codegen/box/bridges/methodFromTrait.kt
index 95c87724b52..46bbf4e80fb 100644
--- a/compiler/testData/codegen/box/bridges/methodFromTrait.kt
+++ b/compiler/testData/codegen/box/bridges/methodFromTrait.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(t: T, u: U) = "A"
}
diff --git a/compiler/testData/codegen/box/bridges/noBridgeOnMutableCollectionInheritance.kt b/compiler/testData/codegen/box/bridges/noBridgeOnMutableCollectionInheritance.kt
index 46ea079d779..6a4fa135a71 100644
--- a/compiler/testData/codegen/box/bridges/noBridgeOnMutableCollectionInheritance.kt
+++ b/compiler/testData/codegen/box/bridges/noBridgeOnMutableCollectionInheritance.kt
@@ -1,11 +1,11 @@
import java.util.ArrayList
import java.util.Arrays
-trait A {
+interface A {
fun foo(): Collection
}
-trait B : A {
+interface B : A {
override fun foo(): MutableCollection
}
diff --git a/compiler/testData/codegen/box/bridges/objectClone.kt b/compiler/testData/codegen/box/bridges/objectClone.kt
index 359cacc6764..266bd90f610 100644
--- a/compiler/testData/codegen/box/bridges/objectClone.kt
+++ b/compiler/testData/codegen/box/bridges/objectClone.kt
@@ -1,7 +1,7 @@
// TARGET_BACKEND: JVM
import java.util.HashSet
-trait A : Set
+interface A : Set
class B : A, HashSet() {
override fun clone(): B = throw AssertionError()
diff --git a/compiler/testData/codegen/box/bridges/propertyDiamond.kt b/compiler/testData/codegen/box/bridges/propertyDiamond.kt
index 5f8a54a1588..802f6f77932 100644
--- a/compiler/testData/codegen/box/bridges/propertyDiamond.kt
+++ b/compiler/testData/codegen/box/bridges/propertyDiamond.kt
@@ -1,11 +1,11 @@
-trait A {
+interface A {
val o: O
val k: K
}
-trait B : A
+interface B : A
-trait C : A
+interface C : A
class D : B, C {
override val o = "O"
diff --git a/compiler/testData/codegen/box/bridges/propertyInConstructor.kt b/compiler/testData/codegen/box/bridges/propertyInConstructor.kt
index 1bc200b1b5c..9ca1e8bf8f5 100644
--- a/compiler/testData/codegen/box/bridges/propertyInConstructor.kt
+++ b/compiler/testData/codegen/box/bridges/propertyInConstructor.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
var x: T
}
diff --git a/compiler/testData/codegen/box/bridges/propertySetter.kt b/compiler/testData/codegen/box/bridges/propertySetter.kt
index b26bed9f0fb..a258dc85346 100644
--- a/compiler/testData/codegen/box/bridges/propertySetter.kt
+++ b/compiler/testData/codegen/box/bridges/propertySetter.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
var v: T
}
diff --git a/compiler/testData/codegen/box/bridges/simpleEnum.kt b/compiler/testData/codegen/box/bridges/simpleEnum.kt
index b4f682850ac..11b715d6c18 100644
--- a/compiler/testData/codegen/box/bridges/simpleEnum.kt
+++ b/compiler/testData/codegen/box/bridges/simpleEnum.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
open fun foo(t: T) = "A"
}
diff --git a/compiler/testData/codegen/box/bridges/simpleTraitImpl.kt b/compiler/testData/codegen/box/bridges/simpleTraitImpl.kt
index 9cd6c1d6b5f..4d2a723aaad 100644
--- a/compiler/testData/codegen/box/bridges/simpleTraitImpl.kt
+++ b/compiler/testData/codegen/box/bridges/simpleTraitImpl.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(t: T) = "A"
}
diff --git a/compiler/testData/codegen/box/bridges/substitutionInSuperClass/delegation.kt b/compiler/testData/codegen/box/bridges/substitutionInSuperClass/delegation.kt
index d469bf5d7f6..ae0d6317dfe 100644
--- a/compiler/testData/codegen/box/bridges/substitutionInSuperClass/delegation.kt
+++ b/compiler/testData/codegen/box/bridges/substitutionInSuperClass/delegation.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun id(t: T): T
}
diff --git a/compiler/testData/codegen/box/bridges/substitutionInSuperClass/enum.kt b/compiler/testData/codegen/box/bridges/substitutionInSuperClass/enum.kt
index 747ca7f6549..ac9d01f3797 100644
--- a/compiler/testData/codegen/box/bridges/substitutionInSuperClass/enum.kt
+++ b/compiler/testData/codegen/box/bridges/substitutionInSuperClass/enum.kt
@@ -1,8 +1,8 @@
-trait A {
+interface A {
open fun foo(t: T) = "A"
}
-trait B : A
+interface B : A
enum class Z(val name: String) : B {
Z1 : Z("Z1")
diff --git a/compiler/testData/codegen/box/bridges/traitImplInheritsTraitImpl.kt b/compiler/testData/codegen/box/bridges/traitImplInheritsTraitImpl.kt
index 1e5a588a0ab..93d02c7fa93 100644
--- a/compiler/testData/codegen/box/bridges/traitImplInheritsTraitImpl.kt
+++ b/compiler/testData/codegen/box/bridges/traitImplInheritsTraitImpl.kt
@@ -1,8 +1,8 @@
-trait A {
+interface A {
fun foo(): Any = "A"
}
-trait B : A {
+interface B : A {
override fun foo(): String = "B"
}
diff --git a/compiler/testData/codegen/box/bridges/traitWithRequiredCovariantOverride.kt b/compiler/testData/codegen/box/bridges/traitWithRequiredCovariantOverride.kt
index 35e0c38a30c..997a5c33760 100644
--- a/compiler/testData/codegen/box/bridges/traitWithRequiredCovariantOverride.kt
+++ b/compiler/testData/codegen/box/bridges/traitWithRequiredCovariantOverride.kt
@@ -2,7 +2,7 @@ open class A {
open fun foo(): Any = "A"
}
-trait B : A {
+interface B : A {
override fun foo(): String = "B"
}
diff --git a/compiler/testData/codegen/box/bridges/twoParentsWithDifferentMethodsTwoBridges.kt b/compiler/testData/codegen/box/bridges/twoParentsWithDifferentMethodsTwoBridges.kt
index 8edaa868640..ba08200e6f2 100644
--- a/compiler/testData/codegen/box/bridges/twoParentsWithDifferentMethodsTwoBridges.kt
+++ b/compiler/testData/codegen/box/bridges/twoParentsWithDifferentMethodsTwoBridges.kt
@@ -1,8 +1,8 @@
-trait A {
+interface A {
fun foo(t: T, u: Int) = "A"
}
-trait B {
+interface B {
fun foo(t: T, u: U) = "B"
}
diff --git a/compiler/testData/codegen/box/bridges/twoParentsWithTheSameMethodOneBridge.kt b/compiler/testData/codegen/box/bridges/twoParentsWithTheSameMethodOneBridge.kt
index 22163c367ef..21ffaa75e18 100644
--- a/compiler/testData/codegen/box/bridges/twoParentsWithTheSameMethodOneBridge.kt
+++ b/compiler/testData/codegen/box/bridges/twoParentsWithTheSameMethodOneBridge.kt
@@ -1,8 +1,8 @@
-trait A {
+interface A {
fun foo(t: T) = "A"
}
-trait B {
+interface B {
fun foo(t: T) = "B"
}
diff --git a/compiler/testData/codegen/box/builtinStubMethods/dontGenerateBodyInTrait.kt b/compiler/testData/codegen/box/builtinStubMethods/dontGenerateBodyInTrait.kt
index 900d979832f..65cfb766528 100644
--- a/compiler/testData/codegen/box/builtinStubMethods/dontGenerateBodyInTrait.kt
+++ b/compiler/testData/codegen/box/builtinStubMethods/dontGenerateBodyInTrait.kt
@@ -1,10 +1,10 @@
-trait A : Collection
-trait B : List
-trait C : Map
-trait D : Map.Entry
-trait E : Iterator
+interface A : Collection
+interface B : List
+interface C : Map
+interface D : Map.Entry
+interface E : Iterator
fun box(): String {
- trait F : A, B, C, D, E
+ interface F : A, B, C, D, E
return "OK"
}
diff --git a/compiler/testData/codegen/box/builtinStubMethods/implementationInTrait.kt b/compiler/testData/codegen/box/builtinStubMethods/implementationInTrait.kt
index d08887a8854..7baaa46e2f8 100644
--- a/compiler/testData/codegen/box/builtinStubMethods/implementationInTrait.kt
+++ b/compiler/testData/codegen/box/builtinStubMethods/implementationInTrait.kt
@@ -1,4 +1,4 @@
-trait Addable {
+interface Addable {
fun add(s: String): Boolean = true
}
diff --git a/compiler/testData/codegen/box/classes/classObjectInTrait.kt b/compiler/testData/codegen/box/classes/classObjectInTrait.kt
index cff3e374654..e34f5622a3e 100644
--- a/compiler/testData/codegen/box/classes/classObjectInTrait.kt
+++ b/compiler/testData/codegen/box/classes/classObjectInTrait.kt
@@ -1,6 +1,6 @@
// EA-38323 - Illegal field modifiers in class: classObject field in C must be static and final
-trait C {
+interface C {
companion object {
public val FOO: String = "OK"
}
diff --git a/compiler/testData/codegen/box/classes/delegation2.kt b/compiler/testData/codegen/box/classes/delegation2.kt
index 83a4028d53e..81b8b0fb47e 100644
--- a/compiler/testData/codegen/box/classes/delegation2.kt
+++ b/compiler/testData/codegen/box/classes/delegation2.kt
@@ -1,8 +1,8 @@
-trait Trait1 {
+interface Trait1 {
fun foo() : String
}
-trait Trait2 {
+interface Trait2 {
fun bar() : String
}
diff --git a/compiler/testData/codegen/box/classes/delegation3.kt b/compiler/testData/codegen/box/classes/delegation3.kt
index 33d2ed5b9e0..fd4f07800a2 100644
--- a/compiler/testData/codegen/box/classes/delegation3.kt
+++ b/compiler/testData/codegen/box/classes/delegation3.kt
@@ -1,8 +1,8 @@
-trait One {
+interface One {
public open fun foo() : Int
public open fun faz() : Int = 10
}
-trait Two {
+interface Two {
public open fun foo() : Int
public open fun quux() : Int = 100
}
diff --git a/compiler/testData/codegen/box/classes/delegation4.kt b/compiler/testData/codegen/box/classes/delegation4.kt
index a37cb061d7c..d29ddb16c89 100644
--- a/compiler/testData/codegen/box/classes/delegation4.kt
+++ b/compiler/testData/codegen/box/classes/delegation4.kt
@@ -1,8 +1,8 @@
-open trait First {
+open interface First {
public open fun foo() : Int
}
-open trait Second : First {
+open interface Second : First {
public open fun bar() : Int
}
diff --git a/compiler/testData/codegen/box/classes/delegationGenericArg.kt b/compiler/testData/codegen/box/classes/delegationGenericArg.kt
index fed9f214dd8..f298e834f79 100644
--- a/compiler/testData/codegen/box/classes/delegationGenericArg.kt
+++ b/compiler/testData/codegen/box/classes/delegationGenericArg.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(t: T): String
}
diff --git a/compiler/testData/codegen/box/classes/delegationGenericArgUpperBound.kt b/compiler/testData/codegen/box/classes/delegationGenericArgUpperBound.kt
index b5da8aaffee..72e541b7f3b 100644
--- a/compiler/testData/codegen/box/classes/delegationGenericArgUpperBound.kt
+++ b/compiler/testData/codegen/box/classes/delegationGenericArgUpperBound.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(t: T): String
}
diff --git a/compiler/testData/codegen/box/classes/delegationGenericLongArg.kt b/compiler/testData/codegen/box/classes/delegationGenericLongArg.kt
index df80d1064e6..8bd117f9fa1 100644
--- a/compiler/testData/codegen/box/classes/delegationGenericLongArg.kt
+++ b/compiler/testData/codegen/box/classes/delegationGenericLongArg.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(t: T, u: U): String
}
diff --git a/compiler/testData/codegen/box/classes/delegationMethodsWithArgs.kt b/compiler/testData/codegen/box/classes/delegationMethodsWithArgs.kt
index dc84a1ed194..a8c0e37230c 100644
--- a/compiler/testData/codegen/box/classes/delegationMethodsWithArgs.kt
+++ b/compiler/testData/codegen/box/classes/delegationMethodsWithArgs.kt
@@ -1,14 +1,14 @@
package test
-trait TextField {
+interface TextField {
fun getText(): String
}
-trait InputTextField : TextField {
+interface InputTextField : TextField {
fun setText(text: String)
}
-trait MooableTextField : InputTextField {
+interface MooableTextField : InputTextField {
fun moo(a: Int, b: Int, c: Int): Int
}
diff --git a/compiler/testData/codegen/box/classes/diamondInheritance.kt b/compiler/testData/codegen/box/classes/diamondInheritance.kt
index 447036bf49b..f20f33ab2cd 100644
--- a/compiler/testData/codegen/box/classes/diamondInheritance.kt
+++ b/compiler/testData/codegen/box/classes/diamondInheritance.kt
@@ -5,7 +5,7 @@ open class Base() {
}
open class Left() : Base() {}
-trait Right : Base {}
+interface Right : Base {}
class D() : Left(), Right
diff --git a/compiler/testData/codegen/box/classes/funDelegation.kt b/compiler/testData/codegen/box/classes/funDelegation.kt
index f940e8e16c9..2a75f698109 100644
--- a/compiler/testData/codegen/box/classes/funDelegation.kt
+++ b/compiler/testData/codegen/box/classes/funDelegation.kt
@@ -2,7 +2,7 @@ open class Base() {
fun n(n : Int) : Int = n + 1
}
-trait Abstract {}
+interface Abstract {}
class Derived1() : Base(), Abstract {}
class Derived2() : Abstract, Base() {}
diff --git a/compiler/testData/codegen/box/classes/inheritSetAndHashSet.kt b/compiler/testData/codegen/box/classes/inheritSetAndHashSet.kt
index b7711f77748..dce4e5da005 100644
--- a/compiler/testData/codegen/box/classes/inheritSetAndHashSet.kt
+++ b/compiler/testData/codegen/box/classes/inheritSetAndHashSet.kt
@@ -1,6 +1,6 @@
import java.util.HashSet
-trait A : Set
+interface A : Set
class B : A, HashSet()
diff --git a/compiler/testData/codegen/box/classes/inheritance.kt b/compiler/testData/codegen/box/classes/inheritance.kt
index 1b919497b5c..78d6d58fa3b 100644
--- a/compiler/testData/codegen/box/classes/inheritance.kt
+++ b/compiler/testData/codegen/box/classes/inheritance.kt
@@ -1,7 +1,7 @@
// Changed when traits were introduced. May not make sense any more
open class X(val x : Int) {}
-trait Y {
+interface Y {
abstract val y : Int
}
@@ -11,7 +11,7 @@ class Point(x : Int, yy : Int) : X(x) , Y {
override val y : Int = yy
}
-trait Abstract {}
+interface Abstract {}
class P1(x : Int, yy : Y) : Abstract, X(x), Y by yy {}
class P2(x : Int, yy : Y) : X(x), Abstract, Y by yy {}
diff --git a/compiler/testData/codegen/box/classes/kt1345.kt b/compiler/testData/codegen/box/classes/kt1345.kt
index 28d9467076a..3933f9c552e 100644
--- a/compiler/testData/codegen/box/classes/kt1345.kt
+++ b/compiler/testData/codegen/box/classes/kt1345.kt
@@ -1,10 +1,10 @@
-trait Creator {
+interface Creator {
fun create() : T
}
class Actor(val code: String = "OK")
-trait Factory : Creator
+interface Factory : Creator
class MyFactory() : Factory {
override fun create(): Actor = Actor()
diff --git a/compiler/testData/codegen/box/classes/kt1918.kt b/compiler/testData/codegen/box/classes/kt1918.kt
index 7dabde92a46..1da1471e2d3 100644
--- a/compiler/testData/codegen/box/classes/kt1918.kt
+++ b/compiler/testData/codegen/box/classes/kt1918.kt
@@ -1,7 +1,7 @@
class Bar {
}
-trait Foo {
+interface Foo {
fun xyzzy(x: Any?): String
}
diff --git a/compiler/testData/codegen/box/classes/kt2224.kt b/compiler/testData/codegen/box/classes/kt2224.kt
index 83c8cb44b86..fe6d9bcbe48 100644
--- a/compiler/testData/codegen/box/classes/kt2224.kt
+++ b/compiler/testData/codegen/box/classes/kt2224.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(): Int
}
diff --git a/compiler/testData/codegen/box/classes/kt2390.kt b/compiler/testData/codegen/box/classes/kt2390.kt
index 18366e5222f..9d664ee825d 100644
--- a/compiler/testData/codegen/box/classes/kt2390.kt
+++ b/compiler/testData/codegen/box/classes/kt2390.kt
@@ -5,18 +5,18 @@ class JsonObject() {
class JsonArray() {
}
-public trait Formatter {
+public interface Formatter {
public fun format(source: IN?): OUT
}
-public trait MultiFormatter {
+public interface MultiFormatter {
public fun format(source: Collection): OUT
}
public class Project() {
}
-public trait JsonFormatter: Formatter, MultiFormatter {
+public interface JsonFormatter: Formatter, MultiFormatter {
public override fun format(source: Collection): JsonArray {
return JsonArray();
}
diff --git a/compiler/testData/codegen/box/classes/kt2391.kt b/compiler/testData/codegen/box/classes/kt2391.kt
index 005c5715d29..2176c01b98e 100644
--- a/compiler/testData/codegen/box/classes/kt2391.kt
+++ b/compiler/testData/codegen/box/classes/kt2391.kt
@@ -1,4 +1,4 @@
-public trait LoggerAware {
+public interface LoggerAware {
public val logger: StringBuilder
}
diff --git a/compiler/testData/codegen/box/classes/kt2477.kt b/compiler/testData/codegen/box/classes/kt2477.kt
index a18e8731ab6..bd449eefb43 100644
--- a/compiler/testData/codegen/box/classes/kt2477.kt
+++ b/compiler/testData/codegen/box/classes/kt2477.kt
@@ -1,11 +1,11 @@
package test
-trait A {
+interface A {
public val c: String
get() = "OK"
}
-trait B {
+interface B {
protected val c: String
}
diff --git a/compiler/testData/codegen/box/classes/kt2532.kt b/compiler/testData/codegen/box/classes/kt2532.kt
index a3a0a4a0d35..24d12e9f884 100644
--- a/compiler/testData/codegen/box/classes/kt2532.kt
+++ b/compiler/testData/codegen/box/classes/kt2532.kt
@@ -1,6 +1,6 @@
package foo
-trait B {
+interface B {
val c: Int
get() = 2
}
diff --git a/compiler/testData/codegen/box/classes/kt2566.kt b/compiler/testData/codegen/box/classes/kt2566.kt
index fff411738e8..6a134feb84f 100644
--- a/compiler/testData/codegen/box/classes/kt2566.kt
+++ b/compiler/testData/codegen/box/classes/kt2566.kt
@@ -6,7 +6,7 @@ open class B : A() {
override fun foo() = super.foo()
}
-trait I
+interface I
class C : I, B() {
override fun foo() = super.foo()
diff --git a/compiler/testData/codegen/box/classes/kt285.kt b/compiler/testData/codegen/box/classes/kt285.kt
index 4c47239d8ae..514d086e8d3 100644
--- a/compiler/testData/codegen/box/classes/kt285.kt
+++ b/compiler/testData/codegen/box/classes/kt285.kt
@@ -1,4 +1,4 @@
-trait Trait {
+interface Trait {
fun foo() = "O"
override fun toString() = "K"
}
diff --git a/compiler/testData/codegen/box/classes/kt3001.kt b/compiler/testData/codegen/box/classes/kt3001.kt
index 35925eade05..0524528ca1e 100644
--- a/compiler/testData/codegen/box/classes/kt3001.kt
+++ b/compiler/testData/codegen/box/classes/kt3001.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
val result: String
}
diff --git a/compiler/testData/codegen/box/classes/kt3414.kt b/compiler/testData/codegen/box/classes/kt3414.kt
index 6770d466086..6b4a083eda9 100644
--- a/compiler/testData/codegen/box/classes/kt3414.kt
+++ b/compiler/testData/codegen/box/classes/kt3414.kt
@@ -1,8 +1,8 @@
-trait A {
+interface A {
fun foo(): Int
}
-trait B {
+interface B {
fun foo(): Int
}
diff --git a/compiler/testData/codegen/box/classes/kt3546.kt b/compiler/testData/codegen/box/classes/kt3546.kt
index 4fb5ce41dd3..b4d36c1f3e6 100644
--- a/compiler/testData/codegen/box/classes/kt3546.kt
+++ b/compiler/testData/codegen/box/classes/kt3546.kt
@@ -1,12 +1,12 @@
-trait A {
+interface A {
fun test(): String
}
-trait B {
+interface B {
fun test(): String
}
-trait C: A, B
+interface C: A, B
class Z(val param: String): C {
diff --git a/compiler/testData/codegen/box/classes/kt3862.kt b/compiler/testData/codegen/box/classes/kt3862.kt
index c6d52a45fc4..6f020ac8ab0 100644
--- a/compiler/testData/codegen/box/classes/kt3862.kt
+++ b/compiler/testData/codegen/box/classes/kt3862.kt
@@ -2,7 +2,7 @@ open class A {
open fun foo(a: T): Int = 2
}
-trait B : A {
+interface B : A {
override fun foo(a: T): Int = 1
}
diff --git a/compiler/testData/codegen/box/classes/propertyDelegation.kt b/compiler/testData/codegen/box/classes/propertyDelegation.kt
index fcf720a21ba..5af5516c859 100644
--- a/compiler/testData/codegen/box/classes/propertyDelegation.kt
+++ b/compiler/testData/codegen/box/classes/propertyDelegation.kt
@@ -10,7 +10,7 @@ open class Base() {
}
}
-trait Abstract {}
+interface Abstract {}
class Derived1() : Base(), Abstract {}
class Derived2() : Abstract, Base() {}
diff --git a/compiler/testData/codegen/box/classes/rightHandOverride.kt b/compiler/testData/codegen/box/classes/rightHandOverride.kt
index 987da6bd6b0..2c5af2c9927 100644
--- a/compiler/testData/codegen/box/classes/rightHandOverride.kt
+++ b/compiler/testData/codegen/box/classes/rightHandOverride.kt
@@ -1,6 +1,6 @@
// Changed when traits were introduced. May not make sense any more
-trait Left {}
+interface Left {}
open class Right() {
open fun f() = 42
}
diff --git a/compiler/testData/codegen/box/classes/typedDelegation.kt b/compiler/testData/codegen/box/classes/typedDelegation.kt
index 0ffd3265146..e0b1241a6aa 100644
--- a/compiler/testData/codegen/box/classes/typedDelegation.kt
+++ b/compiler/testData/codegen/box/classes/typedDelegation.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
var zzzValue : T
fun zzz() : T
}
diff --git a/compiler/testData/codegen/box/closures/captureOuterProperty/captureFunctionInProperty.kt b/compiler/testData/codegen/box/closures/captureOuterProperty/captureFunctionInProperty.kt
index 57d93cb270a..e2c507f3b28 100644
--- a/compiler/testData/codegen/box/closures/captureOuterProperty/captureFunctionInProperty.kt
+++ b/compiler/testData/codegen/box/closures/captureOuterProperty/captureFunctionInProperty.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun result(): String
}
diff --git a/compiler/testData/codegen/box/closures/captureOuterProperty/inFunction.kt b/compiler/testData/codegen/box/closures/captureOuterProperty/inFunction.kt
index 03bdb3b499a..7b4828fa7b5 100644
--- a/compiler/testData/codegen/box/closures/captureOuterProperty/inFunction.kt
+++ b/compiler/testData/codegen/box/closures/captureOuterProperty/inFunction.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun result(): String
}
diff --git a/compiler/testData/codegen/box/closures/captureOuterProperty/inProperty.kt b/compiler/testData/codegen/box/closures/captureOuterProperty/inProperty.kt
index 15769f77148..8f1846f7cfb 100644
--- a/compiler/testData/codegen/box/closures/captureOuterProperty/inProperty.kt
+++ b/compiler/testData/codegen/box/closures/captureOuterProperty/inProperty.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun result(): String
}
diff --git a/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyDeepObjectChain.kt b/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyDeepObjectChain.kt
index 2dfd7949ca6..0bb07f581b9 100644
--- a/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyDeepObjectChain.kt
+++ b/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyDeepObjectChain.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun result(): String
}
diff --git a/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyFromSuperClass.kt b/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyFromSuperClass.kt
index 934d0b58ec7..2f7ff86a10c 100644
--- a/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyFromSuperClass.kt
+++ b/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyFromSuperClass.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun result(): String
}
diff --git a/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyFromSuperSuperClass.kt b/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyFromSuperSuperClass.kt
index 4dc735a2bf7..3d600017d08 100644
--- a/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyFromSuperSuperClass.kt
+++ b/compiler/testData/codegen/box/closures/captureOuterProperty/inPropertyFromSuperSuperClass.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun result(): String
}
diff --git a/compiler/testData/codegen/box/closures/closureInsideClosure/propertyAndFunctionNameClash.kt b/compiler/testData/codegen/box/closures/closureInsideClosure/propertyAndFunctionNameClash.kt
index 0133c48cc07..b19e4b61b0d 100644
--- a/compiler/testData/codegen/box/closures/closureInsideClosure/propertyAndFunctionNameClash.kt
+++ b/compiler/testData/codegen/box/closures/closureInsideClosure/propertyAndFunctionNameClash.kt
@@ -24,7 +24,7 @@ class LI : ListTag() {}
public fun ListTag.item(body: LI.() -> Unit): Unit {}
fun HtmlTag.a(contents: A.() -> Unit) {}
-trait A : HtmlTag {
+interface A : HtmlTag {
public var text: String
}
diff --git a/compiler/testData/codegen/box/controlStructures/emptyFor.kt b/compiler/testData/codegen/box/controlStructures/emptyFor.kt
index fc3f6332871..e39e3997923 100644
--- a/compiler/testData/codegen/box/controlStructures/emptyFor.kt
+++ b/compiler/testData/codegen/box/controlStructures/emptyFor.kt
@@ -1,6 +1,6 @@
var index = 0
-trait IterableIterator : Iterator {
+interface IterableIterator : Iterator {
fun iterator(): Iterator = this
}
diff --git a/compiler/testData/codegen/box/defaultArguments/function/funInTrait.kt b/compiler/testData/codegen/box/defaultArguments/function/funInTrait.kt
index ba7df2c9e0b..06b181e10b6 100644
--- a/compiler/testData/codegen/box/defaultArguments/function/funInTrait.kt
+++ b/compiler/testData/codegen/box/defaultArguments/function/funInTrait.kt
@@ -1,4 +1,4 @@
-trait Foo {
+interface Foo {
fun foo(a: Double = 1.0): Double
}
diff --git a/compiler/testData/codegen/box/defaultArguments/function/trait.kt b/compiler/testData/codegen/box/defaultArguments/function/trait.kt
index b986362f653..91bafe072f3 100644
--- a/compiler/testData/codegen/box/defaultArguments/function/trait.kt
+++ b/compiler/testData/codegen/box/defaultArguments/function/trait.kt
@@ -1,5 +1,5 @@
-trait Base {
- fun bar(a: String = "abc"): String = a + " from trait"
+interface Base {
+ fun bar(a: String = "abc"): String = a + " from interface"
}
class Derived: Base {
diff --git a/compiler/testData/codegen/box/delegatedProperty/inTrait.kt b/compiler/testData/codegen/box/delegatedProperty/inTrait.kt
index f9802ba1e3f..1f5e64731a9 100644
--- a/compiler/testData/codegen/box/delegatedProperty/inTrait.kt
+++ b/compiler/testData/codegen/box/delegatedProperty/inTrait.kt
@@ -2,7 +2,7 @@ class Delegate {
fun get(t: Any?, p: PropertyMetadata): Int = 1
}
-trait A {
+interface A {
val prop: Int
}
diff --git a/compiler/testData/codegen/box/delegatedProperty/kt4138.kt b/compiler/testData/codegen/box/delegatedProperty/kt4138.kt
index d4e52b824b5..f1f85eeaee1 100644
--- a/compiler/testData/codegen/box/delegatedProperty/kt4138.kt
+++ b/compiler/testData/codegen/box/delegatedProperty/kt4138.kt
@@ -11,7 +11,7 @@ class Foo (val f: Int) {
}
}
-trait FooTrait {
+interface FooTrait {
companion object {
val A: Foo by Delegate(Foo(11))
var B: Foo by Delegate(Foo(11))
diff --git a/compiler/testData/codegen/box/delegatedProperty/propertyDelegatedMethod/inTrait.kt b/compiler/testData/codegen/box/delegatedProperty/propertyDelegatedMethod/inTrait.kt
index c721d6b81b9..370b3ec7275 100644
--- a/compiler/testData/codegen/box/delegatedProperty/propertyDelegatedMethod/inTrait.kt
+++ b/compiler/testData/codegen/box/delegatedProperty/propertyDelegatedMethod/inTrait.kt
@@ -4,7 +4,7 @@ class Delegate {
fun propertyDelegated(p: PropertyMetadata) { name = p.name }
}
-trait A {
+interface A {
val prop: String
}
diff --git a/compiler/testData/codegen/box/diagnostics/functions/invoke/onObjects/invokeOnClassObject2.kt b/compiler/testData/codegen/box/diagnostics/functions/invoke/onObjects/invokeOnClassObject2.kt
index 74cb9e4c24e..45495ff0179 100644
--- a/compiler/testData/codegen/box/diagnostics/functions/invoke/onObjects/invokeOnClassObject2.kt
+++ b/compiler/testData/codegen/box/diagnostics/functions/invoke/onObjects/invokeOnClassObject2.kt
@@ -1,4 +1,4 @@
-trait B
+interface B
fun B.invoke(i: Int) = i
diff --git a/compiler/testData/codegen/box/enum/enumInheritedFromTrait.kt b/compiler/testData/codegen/box/enum/enumInheritedFromTrait.kt
index a371c7e27ae..7659029d2b6 100644
--- a/compiler/testData/codegen/box/enum/enumInheritedFromTrait.kt
+++ b/compiler/testData/codegen/box/enum/enumInheritedFromTrait.kt
@@ -11,6 +11,6 @@ enum class MyEnum : T {
}
}
-trait T {
+interface T {
fun f(): String
}
\ No newline at end of file
diff --git a/compiler/testData/codegen/box/extensionFunctions/kt1776.kt b/compiler/testData/codegen/box/extensionFunctions/kt1776.kt
index 2e742d78312..5174d4cc374 100644
--- a/compiler/testData/codegen/box/extensionFunctions/kt1776.kt
+++ b/compiler/testData/codegen/box/extensionFunctions/kt1776.kt
@@ -1,4 +1,4 @@
-trait Expr {
+interface Expr {
public fun ttFun() : Int = 12
}
diff --git a/compiler/testData/codegen/box/extensionFunctions/kt606.kt b/compiler/testData/codegen/box/extensionFunctions/kt606.kt
index ed62435c2c9..5e1de696f70 100644
--- a/compiler/testData/codegen/box/extensionFunctions/kt606.kt
+++ b/compiler/testData/codegen/box/extensionFunctions/kt606.kt
@@ -10,7 +10,7 @@ class StandardPipelineFactory(val config : ChannelPipeline.() -> Unit) : Channel
}
}
-trait ChannelPipeline {
+interface ChannelPipeline {
fun print(any: Any)
}
@@ -19,7 +19,7 @@ class DefaultChannelPipeline : ChannelPipeline {
}
-trait ChannelPipelineFactory {
+interface ChannelPipelineFactory {
fun getPipeline() : ChannelPipeline
}
diff --git a/compiler/testData/codegen/box/fakeOverride/diamondFunction.kt b/compiler/testData/codegen/box/fakeOverride/diamondFunction.kt
index 7c150aaaa7b..da73cd28d7f 100644
--- a/compiler/testData/codegen/box/fakeOverride/diamondFunction.kt
+++ b/compiler/testData/codegen/box/fakeOverride/diamondFunction.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun foo(): Unit
}
@@ -6,7 +6,7 @@ open class A : T {
override fun foo() {}
}
-trait B : T
+interface B : T
class C : A(), B
class D : B, A()
diff --git a/compiler/testData/codegen/box/fakeOverride/function.kt b/compiler/testData/codegen/box/fakeOverride/function.kt
index 1158cddb0c9..af0e02f4f49 100644
--- a/compiler/testData/codegen/box/fakeOverride/function.kt
+++ b/compiler/testData/codegen/box/fakeOverride/function.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun foo(): Unit
}
@@ -9,7 +9,7 @@ open class A : T {
class B : A(), T
class C : T, A()
-trait U : T
+interface U : T
class D : U, A()
class E : A(), U
class F : U, T, A()
diff --git a/compiler/testData/codegen/box/fakeOverride/propertyGetter.kt b/compiler/testData/codegen/box/fakeOverride/propertyGetter.kt
index 0c86e6eacab..c032e3ab837 100644
--- a/compiler/testData/codegen/box/fakeOverride/propertyGetter.kt
+++ b/compiler/testData/codegen/box/fakeOverride/propertyGetter.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
val foo: String
}
@@ -9,7 +9,7 @@ open class A : T {
class B : A(), T
class C : T, A()
-trait U : T
+interface U : T
class D : U, A()
class E : A(), U
diff --git a/compiler/testData/codegen/box/fakeOverride/propertySetter.kt b/compiler/testData/codegen/box/fakeOverride/propertySetter.kt
index 2103491b1ad..c2f623ba448 100644
--- a/compiler/testData/codegen/box/fakeOverride/propertySetter.kt
+++ b/compiler/testData/codegen/box/fakeOverride/propertySetter.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
var result: String
}
diff --git a/compiler/testData/codegen/box/functions/defaultargs4.kt b/compiler/testData/codegen/box/functions/defaultargs4.kt
index 045f17be11f..b98b9a95d64 100644
--- a/compiler/testData/codegen/box/functions/defaultargs4.kt
+++ b/compiler/testData/codegen/box/functions/defaultargs4.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun bar2(arg: Int = 239) : Int
fun bar(arg: Int = 240) : Int = bar2(arg/2)
diff --git a/compiler/testData/codegen/box/functions/defaultargs6.kt b/compiler/testData/codegen/box/functions/defaultargs6.kt
index 21a9faeae3f..90c4e943d5d 100644
--- a/compiler/testData/codegen/box/functions/defaultargs6.kt
+++ b/compiler/testData/codegen/box/functions/defaultargs6.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(x: Int, y: Int = x + 20, z: Int = y * 2) = z
}
diff --git a/compiler/testData/codegen/box/functions/fakeDescriptorWithSeveralOverridenOne.kt b/compiler/testData/codegen/box/functions/fakeDescriptorWithSeveralOverridenOne.kt
index 862108d8b89..0086f8ab719 100644
--- a/compiler/testData/codegen/box/functions/fakeDescriptorWithSeveralOverridenOne.kt
+++ b/compiler/testData/codegen/box/functions/fakeDescriptorWithSeveralOverridenOne.kt
@@ -1,12 +1,12 @@
-trait Named {
+interface Named {
abstract fun getName() : String;
}
-trait MemberDescriptor : Named {}
+interface MemberDescriptor : Named {}
-trait ClassifierDescriptor : Named {}
+interface ClassifierDescriptor : Named {}
-trait ClassDescriptor : MemberDescriptor, ClassifierDescriptor {}
+interface ClassDescriptor : MemberDescriptor, ClassifierDescriptor {}
class ClassDescriptorImpl : ClassDescriptor {
override fun getName(): String {
diff --git a/compiler/testData/codegen/box/functions/kt1199.kt b/compiler/testData/codegen/box/functions/kt1199.kt
index 0d1899c549e..b29953c4862 100644
--- a/compiler/testData/codegen/box/functions/kt1199.kt
+++ b/compiler/testData/codegen/box/functions/kt1199.kt
@@ -1,5 +1,5 @@
-trait MyIterator {
+interface MyIterator {
fun hasNext() : Boolean
fun next() : T
}
diff --git a/compiler/testData/codegen/box/functions/kt1413.kt b/compiler/testData/codegen/box/functions/kt1413.kt
index 6cc787850e1..15b496fb9b9 100644
--- a/compiler/testData/codegen/box/functions/kt1413.kt
+++ b/compiler/testData/codegen/box/functions/kt1413.kt
@@ -1,6 +1,6 @@
package t
-trait I{
+interface I{
fun f()
}
diff --git a/compiler/testData/codegen/box/functions/kt1649_1.kt b/compiler/testData/codegen/box/functions/kt1649_1.kt
index ef16a4645a6..849bf5525ff 100644
--- a/compiler/testData/codegen/box/functions/kt1649_1.kt
+++ b/compiler/testData/codegen/box/functions/kt1649_1.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
val method : (() -> Unit)?
}
diff --git a/compiler/testData/codegen/box/functions/kt1649_2.kt b/compiler/testData/codegen/box/functions/kt1649_2.kt
index e75d9cb4b62..33f420dc3f9 100644
--- a/compiler/testData/codegen/box/functions/kt1649_2.kt
+++ b/compiler/testData/codegen/box/functions/kt1649_2.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
val method : () -> Unit?
}
diff --git a/compiler/testData/codegen/box/innerNested/kt3132.kt b/compiler/testData/codegen/box/innerNested/kt3132.kt
index 9428d2d7fe7..afcee1c6ca1 100644
--- a/compiler/testData/codegen/box/innerNested/kt3132.kt
+++ b/compiler/testData/codegen/box/innerNested/kt3132.kt
@@ -1,5 +1,5 @@
class Test {
- trait Foo { }
+ interface Foo { }
class FooImplNested: Foo { }
diff --git a/compiler/testData/codegen/box/labels/propertyAccessorObject.kt b/compiler/testData/codegen/box/labels/propertyAccessorObject.kt
index 3459ad58cce..1fc9f25aa82 100644
--- a/compiler/testData/codegen/box/labels/propertyAccessorObject.kt
+++ b/compiler/testData/codegen/box/labels/propertyAccessorObject.kt
@@ -1,4 +1,4 @@
-trait Base {
+interface Base {
fun foo(): Int
}
diff --git a/compiler/testData/codegen/box/localClasses/kt2700.kt b/compiler/testData/codegen/box/localClasses/kt2700.kt
index f6964fb8e1e..3baacf0b21f 100644
--- a/compiler/testData/codegen/box/localClasses/kt2700.kt
+++ b/compiler/testData/codegen/box/localClasses/kt2700.kt
@@ -1,6 +1,6 @@
package a.b
-trait Test {
+interface Test {
fun invoke(): String {
return "OK"
}
diff --git a/compiler/testData/codegen/box/localClasses/kt3210.kt b/compiler/testData/codegen/box/localClasses/kt3210.kt
index da90a52d584..12c9b1cba6e 100644
--- a/compiler/testData/codegen/box/localClasses/kt3210.kt
+++ b/compiler/testData/codegen/box/localClasses/kt3210.kt
@@ -1,12 +1,12 @@
package org.example
-trait SomeTrait {}
+interface SomeTrait {}
-trait KotlinProcessor {
+interface KotlinProcessor {
fun execute(callback: KotlinCallback?);
}
-trait KotlinCallback {
+interface KotlinCallback {
fun on(t : T);
}
diff --git a/compiler/testData/codegen/box/objects/anonymousObjectPropertyInitialization.kt b/compiler/testData/codegen/box/objects/anonymousObjectPropertyInitialization.kt
index a46db9d4e66..4765e8858ba 100644
--- a/compiler/testData/codegen/box/objects/anonymousObjectPropertyInitialization.kt
+++ b/compiler/testData/codegen/box/objects/anonymousObjectPropertyInitialization.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun foo(): String
}
diff --git a/compiler/testData/codegen/box/objects/kt4086.kt b/compiler/testData/codegen/box/objects/kt4086.kt
index e28c8e5fca4..2aa1ca343d8 100644
--- a/compiler/testData/codegen/box/objects/kt4086.kt
+++ b/compiler/testData/codegen/box/objects/kt4086.kt
@@ -1,4 +1,4 @@
-trait N
+interface N
open class Base(n: N)
diff --git a/compiler/testData/codegen/box/objects/objectWithSuperclassAndTrait.kt b/compiler/testData/codegen/box/objects/objectWithSuperclassAndTrait.kt
index ad0d2513d01..c239a3eff27 100644
--- a/compiler/testData/codegen/box/objects/objectWithSuperclassAndTrait.kt
+++ b/compiler/testData/codegen/box/objects/objectWithSuperclassAndTrait.kt
@@ -4,7 +4,7 @@ open class A {
}
}
-trait T {
+interface T {
open fun foo(): Int {
return 3
}
diff --git a/compiler/testData/codegen/box/objects/privateFunctionFromClosureInInitializer_kt5582.kt b/compiler/testData/codegen/box/objects/privateFunctionFromClosureInInitializer_kt5582.kt
index 833336b325c..5b71ab435fe 100644
--- a/compiler/testData/codegen/box/objects/privateFunctionFromClosureInInitializer_kt5582.kt
+++ b/compiler/testData/codegen/box/objects/privateFunctionFromClosureInInitializer_kt5582.kt
@@ -1,4 +1,4 @@
-trait T
+interface T
object Foo {
private fun foo(p: T) = p
diff --git a/compiler/testData/codegen/box/operatorConventions/compareTo/comparable.kt b/compiler/testData/codegen/box/operatorConventions/compareTo/comparable.kt
index fec5ac5bfa0..957816c8974 100644
--- a/compiler/testData/codegen/box/operatorConventions/compareTo/comparable.kt
+++ b/compiler/testData/codegen/box/operatorConventions/compareTo/comparable.kt
@@ -1,4 +1,4 @@
-trait A : Comparable
+interface A : Comparable
class B(val x: Int) : A {
override fun compareTo(other: A) = x.compareTo((other as B).x)
diff --git a/compiler/testData/codegen/box/properties/kt1714.kt b/compiler/testData/codegen/box/properties/kt1714.kt
index 655312cc2b7..87696e39e7f 100644
--- a/compiler/testData/codegen/box/properties/kt1714.kt
+++ b/compiler/testData/codegen/box/properties/kt1714.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
val method : (() -> Unit )?
val test : Integer
}
diff --git a/compiler/testData/codegen/box/properties/kt1714_minimal.kt b/compiler/testData/codegen/box/properties/kt1714_minimal.kt
index dd255aa79f7..e453069c4ad 100644
--- a/compiler/testData/codegen/box/properties/kt1714_minimal.kt
+++ b/compiler/testData/codegen/box/properties/kt1714_minimal.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
val v: Int
}
diff --git a/compiler/testData/codegen/box/properties/kt2655.kt b/compiler/testData/codegen/box/properties/kt2655.kt
index 36244dcee3f..3956fb3a17d 100644
--- a/compiler/testData/codegen/box/properties/kt2655.kt
+++ b/compiler/testData/codegen/box/properties/kt2655.kt
@@ -1,4 +1,4 @@
-trait TextField {
+interface TextField {
fun getText(): String
fun setText(text: String)
}
diff --git a/compiler/testData/codegen/box/properties/kt2786.kt b/compiler/testData/codegen/box/properties/kt2786.kt
index 7b813217918..003ca536275 100644
--- a/compiler/testData/codegen/box/properties/kt2786.kt
+++ b/compiler/testData/codegen/box/properties/kt2786.kt
@@ -1,4 +1,4 @@
-trait FooTrait {
+interface FooTrait {
val propertyTest: String
}
diff --git a/compiler/testData/codegen/box/properties/kt4373.kt b/compiler/testData/codegen/box/properties/kt4373.kt
index 74d2ae00485..41b781f2cfc 100644
--- a/compiler/testData/codegen/box/properties/kt4373.kt
+++ b/compiler/testData/codegen/box/properties/kt4373.kt
@@ -1,4 +1,4 @@
-trait Tr {
+interface Tr {
val prop: T
}
diff --git a/compiler/testData/codegen/box/properties/primitiveOverrideDefaultAccessor.kt b/compiler/testData/codegen/box/properties/primitiveOverrideDefaultAccessor.kt
index eabdf4c4050..e8039fa4cc7 100644
--- a/compiler/testData/codegen/box/properties/primitiveOverrideDefaultAccessor.kt
+++ b/compiler/testData/codegen/box/properties/primitiveOverrideDefaultAccessor.kt
@@ -1,4 +1,4 @@
-trait R> {
+interface R> {
var value: T
}
diff --git a/compiler/testData/codegen/box/properties/primitiveOverrideDelegateAccessor.kt b/compiler/testData/codegen/box/properties/primitiveOverrideDelegateAccessor.kt
index c757476551a..315732f3f1f 100644
--- a/compiler/testData/codegen/box/properties/primitiveOverrideDelegateAccessor.kt
+++ b/compiler/testData/codegen/box/properties/primitiveOverrideDelegateAccessor.kt
@@ -3,7 +3,7 @@ class Holder(var value: Int) {
fun set(that: Any?, desc: PropertyMetadata, newValue: Int) { value = newValue }
}
-trait R> {
+interface R> {
var value: T
}
diff --git a/compiler/testData/codegen/box/properties/traitExtendsClass.kt b/compiler/testData/codegen/box/properties/traitExtendsClass.kt
index 96726168446..d1aa10bec1a 100644
--- a/compiler/testData/codegen/box/properties/traitExtendsClass.kt
+++ b/compiler/testData/codegen/box/properties/traitExtendsClass.kt
@@ -2,7 +2,7 @@ open class Base {
val pr : String = "OK"
}
-trait Trait : Base {
+interface Trait : Base {
fun f() : String {
return this.pr
}
diff --git a/compiler/testData/codegen/box/secondaryConstructors/delegationWithPrimary.kt b/compiler/testData/codegen/box/secondaryConstructors/delegationWithPrimary.kt
index 2ab364d1d71..16f433527f9 100644
--- a/compiler/testData/codegen/box/secondaryConstructors/delegationWithPrimary.kt
+++ b/compiler/testData/codegen/box/secondaryConstructors/delegationWithPrimary.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(): String
}
diff --git a/compiler/testData/codegen/box/super/basicmethodSuperTrait.kt b/compiler/testData/codegen/box/super/basicmethodSuperTrait.kt
index 29d7cbd13ec..c147c0b8b1c 100644
--- a/compiler/testData/codegen/box/super/basicmethodSuperTrait.kt
+++ b/compiler/testData/codegen/box/super/basicmethodSuperTrait.kt
@@ -1,6 +1,6 @@
import java.util.ArrayList
-trait Tr {
+interface Tr {
fun extra() : String = "_"
}
diff --git a/compiler/testData/codegen/box/super/enclosedFun.kt b/compiler/testData/codegen/box/super/enclosedFun.kt
index 1bc7a0a7640..5f317b46f77 100644
--- a/compiler/testData/codegen/box/super/enclosedFun.kt
+++ b/compiler/testData/codegen/box/super/enclosedFun.kt
@@ -1,8 +1,8 @@
-trait BK {
+interface BK {
fun x() : Int = 50
}
-trait K : BK {
+interface K : BK {
override fun x() : Int = super.x() * 2
}
diff --git a/compiler/testData/codegen/box/super/innerClassLabeledSuper.kt b/compiler/testData/codegen/box/super/innerClassLabeledSuper.kt
index 9d405bd2317..cbb0a875df9 100644
--- a/compiler/testData/codegen/box/super/innerClassLabeledSuper.kt
+++ b/compiler/testData/codegen/box/super/innerClassLabeledSuper.kt
@@ -1,9 +1,9 @@
-trait BK {
+interface BK {
fun foo(): String
fun bar(): String
}
-trait K : BK {
+interface K : BK {
override fun foo() = bar()
}
diff --git a/compiler/testData/codegen/box/super/innerClassLabeledSuper2.kt b/compiler/testData/codegen/box/super/innerClassLabeledSuper2.kt
index f7681e7e67e..1a0bca8c437 100644
--- a/compiler/testData/codegen/box/super/innerClassLabeledSuper2.kt
+++ b/compiler/testData/codegen/box/super/innerClassLabeledSuper2.kt
@@ -1,10 +1,10 @@
//inspired by kt3492
-trait BK {
+interface BK {
fun foo(): String
fun bar(): String
}
-trait KTrait: BK {
+interface KTrait: BK {
override fun foo() = bar()
}
diff --git a/compiler/testData/codegen/box/super/innerClassLabeledSuperProperty.kt b/compiler/testData/codegen/box/super/innerClassLabeledSuperProperty.kt
index 4f4a62f8850..bb8098564f6 100644
--- a/compiler/testData/codegen/box/super/innerClassLabeledSuperProperty.kt
+++ b/compiler/testData/codegen/box/super/innerClassLabeledSuperProperty.kt
@@ -1,4 +1,4 @@
-trait Base {
+interface Base {
val foo: String
fun bar(): String
}
diff --git a/compiler/testData/codegen/box/super/innerClassLabeledSuperProperty2.kt b/compiler/testData/codegen/box/super/innerClassLabeledSuperProperty2.kt
index ad6f8ddf94c..effc71e7925 100644
--- a/compiler/testData/codegen/box/super/innerClassLabeledSuperProperty2.kt
+++ b/compiler/testData/codegen/box/super/innerClassLabeledSuperProperty2.kt
@@ -1,5 +1,5 @@
//inspired by kt3492
-trait Base {
+interface Base {
val foo: String
fun bar(): String
}
diff --git a/compiler/testData/codegen/box/super/kt3492TraitFun.kt b/compiler/testData/codegen/box/super/kt3492TraitFun.kt
index 19c9a2920c0..144e86036a3 100644
--- a/compiler/testData/codegen/box/super/kt3492TraitFun.kt
+++ b/compiler/testData/codegen/box/super/kt3492TraitFun.kt
@@ -1,4 +1,4 @@
-trait ATrait {
+interface ATrait {
open fun foo2(): String = "OK"
}
diff --git a/compiler/testData/codegen/box/super/kt3492TraitProperty.kt b/compiler/testData/codegen/box/super/kt3492TraitProperty.kt
index bfd7859f19f..c4c3298afcb 100644
--- a/compiler/testData/codegen/box/super/kt3492TraitProperty.kt
+++ b/compiler/testData/codegen/box/super/kt3492TraitProperty.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
open val foo: String
get() = "OK"
}
diff --git a/compiler/testData/codegen/box/super/kt3538.kt b/compiler/testData/codegen/box/super/kt3538.kt
index 47656e7b4df..7186da045ec 100644
--- a/compiler/testData/codegen/box/super/kt3538.kt
+++ b/compiler/testData/codegen/box/super/kt3538.kt
@@ -4,7 +4,7 @@ open class Base {
}
}
-trait Trait: Base {
+interface Trait: Base {
override fun sayHello(): String {
return "K"
}
diff --git a/compiler/testData/codegen/box/super/multipleSuperTraits.kt b/compiler/testData/codegen/box/super/multipleSuperTraits.kt
index 2312888b2fa..2ddb25d35b9 100644
--- a/compiler/testData/codegen/box/super/multipleSuperTraits.kt
+++ b/compiler/testData/codegen/box/super/multipleSuperTraits.kt
@@ -1,8 +1,8 @@
-trait T1 {
+interface T1 {
fun foo() = "O"
}
-trait T2 {
+interface T2 {
fun foo() = "K"
}
diff --git a/compiler/testData/codegen/box/super/traitproperty.kt b/compiler/testData/codegen/box/super/traitproperty.kt
index 820d99402a7..a5de71c24eb 100644
--- a/compiler/testData/codegen/box/super/traitproperty.kt
+++ b/compiler/testData/codegen/box/super/traitproperty.kt
@@ -1,4 +1,4 @@
-trait M {
+interface M {
var backingB : Int
var b : Int
get() = backingB
diff --git a/compiler/testData/codegen/box/superConstructorCall/deepLocalHierarchy.kt b/compiler/testData/codegen/box/superConstructorCall/deepLocalHierarchy.kt
index 51a059cb0a3..534370e134e 100644
--- a/compiler/testData/codegen/box/superConstructorCall/deepLocalHierarchy.kt
+++ b/compiler/testData/codegen/box/superConstructorCall/deepLocalHierarchy.kt
@@ -1,5 +1,5 @@
fun box(): String {
- open trait L1 {
+ open interface L1 {
fun foo(): String
}
diff --git a/compiler/testData/codegen/box/traits/finalMethod.kt b/compiler/testData/codegen/box/traits/finalMethod.kt
index 1469b0e10fb..443d02c1cf4 100644
--- a/compiler/testData/codegen/box/traits/finalMethod.kt
+++ b/compiler/testData/codegen/box/traits/finalMethod.kt
@@ -1,6 +1,6 @@
//KT-2382
-trait T {
+interface T {
final fun foo() = "OK"
}
diff --git a/compiler/testData/codegen/box/traits/genericMethod.kt b/compiler/testData/codegen/box/traits/genericMethod.kt
index 06fa2f35a31..e3d47b24181 100644
--- a/compiler/testData/codegen/box/traits/genericMethod.kt
+++ b/compiler/testData/codegen/box/traits/genericMethod.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
val property : T
open fun a() : T {
diff --git a/compiler/testData/codegen/box/traits/inheritedFun.kt b/compiler/testData/codegen/box/traits/inheritedFun.kt
index 1262b29ba06..756aed226c7 100644
--- a/compiler/testData/codegen/box/traits/inheritedFun.kt
+++ b/compiler/testData/codegen/box/traits/inheritedFun.kt
@@ -1,5 +1,5 @@
//KT-2206
-trait A {
+interface A {
fun f():Int = 239
}
diff --git a/compiler/testData/codegen/box/traits/inheritedVar.kt b/compiler/testData/codegen/box/traits/inheritedVar.kt
index f1aa0ab825b..887f33c2178 100644
--- a/compiler/testData/codegen/box/traits/inheritedVar.kt
+++ b/compiler/testData/codegen/box/traits/inheritedVar.kt
@@ -1,6 +1,6 @@
//KT-2206
-trait A {
+interface A {
var a:Int
get() = 239
set(value) {
diff --git a/compiler/testData/codegen/box/traits/kt1936.kt b/compiler/testData/codegen/box/traits/kt1936.kt
index 7361d996893..0764dca3de4 100644
--- a/compiler/testData/codegen/box/traits/kt1936.kt
+++ b/compiler/testData/codegen/box/traits/kt1936.kt
@@ -1,6 +1,6 @@
var result = "Fail"
-trait MyTrait
+interface MyTrait
{
var property : String
fun foo() {
diff --git a/compiler/testData/codegen/box/traits/kt1936_1.kt b/compiler/testData/codegen/box/traits/kt1936_1.kt
index b79da2cf44e..c3c6ef815f6 100644
--- a/compiler/testData/codegen/box/traits/kt1936_1.kt
+++ b/compiler/testData/codegen/box/traits/kt1936_1.kt
@@ -1,4 +1,4 @@
-trait MyTrait
+interface MyTrait
{
var property : String
fun foo() = property
diff --git a/compiler/testData/codegen/box/traits/kt2260.kt b/compiler/testData/codegen/box/traits/kt2260.kt
index b3f39f8234c..f63a2220542 100644
--- a/compiler/testData/codegen/box/traits/kt2260.kt
+++ b/compiler/testData/codegen/box/traits/kt2260.kt
@@ -1,4 +1,4 @@
-trait Flusher {
+interface Flusher {
fun flush() = "OK"
}
diff --git a/compiler/testData/codegen/box/traits/kt2399.kt b/compiler/testData/codegen/box/traits/kt2399.kt
index d53fc22bf53..6d26c72c134 100644
--- a/compiler/testData/codegen/box/traits/kt2399.kt
+++ b/compiler/testData/codegen/box/traits/kt2399.kt
@@ -10,15 +10,15 @@ class ProjectInfo {
override fun toString(): String = "OK"
}
-public trait Parser {
+public interface Parser {
public fun parse(source: IN): OUT
}
-public trait MultiParser {
+public interface MultiParser {
public fun parse(source: IN): Collection
}
-public trait JsonParser: Parser, MultiParser {
+public interface JsonParser: Parser, MultiParser {
public override fun parse(source: JsonArray): Collection {
return ArrayList()
}
diff --git a/compiler/testData/codegen/box/traits/kt2541.kt b/compiler/testData/codegen/box/traits/kt2541.kt
index c054d5fbadc..5be4abf0272 100644
--- a/compiler/testData/codegen/box/traits/kt2541.kt
+++ b/compiler/testData/codegen/box/traits/kt2541.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(t: T, u: U) = "OK"
}
diff --git a/compiler/testData/codegen/box/traits/kt3315.kt b/compiler/testData/codegen/box/traits/kt3315.kt
index 7a0e3262554..91f7f81a489 100644
--- a/compiler/testData/codegen/box/traits/kt3315.kt
+++ b/compiler/testData/codegen/box/traits/kt3315.kt
@@ -1,4 +1,4 @@
-trait B {
+interface B {
fun foo(dd: T): T = dd
}
diff --git a/compiler/testData/codegen/box/traits/kt3500.kt b/compiler/testData/codegen/box/traits/kt3500.kt
index ba3e63ce5ca..18433df514a 100644
--- a/compiler/testData/codegen/box/traits/kt3500.kt
+++ b/compiler/testData/codegen/box/traits/kt3500.kt
@@ -1,8 +1,8 @@
-trait BK {
+interface BK {
fun foo(): String = 10.toString()
}
-trait KTrait: BK {
+interface KTrait: BK {
override fun foo() = 30.toString()
}
diff --git a/compiler/testData/codegen/box/traits/kt5495.kt b/compiler/testData/codegen/box/traits/kt5495.kt
index 7a78baa0b9b..5d541929589 100644
--- a/compiler/testData/codegen/box/traits/kt5495.kt
+++ b/compiler/testData/codegen/box/traits/kt5495.kt
@@ -1,5 +1,5 @@
fun box(): String {
- trait A {
+ interface A {
fun foo() = "OK"
}
diff --git a/compiler/testData/codegen/box/traits/multiple.kt b/compiler/testData/codegen/box/traits/multiple.kt
index da0c9da4a36..bc6470c0d6b 100644
--- a/compiler/testData/codegen/box/traits/multiple.kt
+++ b/compiler/testData/codegen/box/traits/multiple.kt
@@ -1,8 +1,8 @@
-trait AL {
+interface AL {
fun get(index: Int) : Any? = null
}
-trait ALE : AL {
+interface ALE : AL {
fun getOrNull(index: Int, value: T) : T {
val r = get(index) as? T
return r ?: value
diff --git a/compiler/testData/codegen/box/traits/traitWithPrivateExtension.kt b/compiler/testData/codegen/box/traits/traitWithPrivateExtension.kt
index 64b307eb1f9..5dee33c0792 100644
--- a/compiler/testData/codegen/box/traits/traitWithPrivateExtension.kt
+++ b/compiler/testData/codegen/box/traits/traitWithPrivateExtension.kt
@@ -4,7 +4,7 @@ open class B {
class BB : B()
-trait Z {
+interface Z {
fun T.getString() : String {
return p
}
diff --git a/compiler/testData/codegen/box/traits/withRequired/generic.kt b/compiler/testData/codegen/box/traits/withRequired/generic.kt
index bb5f05817b9..75d26e62299 100644
--- a/compiler/testData/codegen/box/traits/withRequired/generic.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/generic.kt
@@ -2,7 +2,7 @@ open class AL {
fun get(index: Int) : T? = null
}
-trait ALE : AL {
+interface ALE : AL {
fun getOrValue(index: Int, value : T) : T = get(index) ?: value
}
diff --git a/compiler/testData/codegen/box/traits/withRequired/genericProperty.kt b/compiler/testData/codegen/box/traits/withRequired/genericProperty.kt
index 23019a5e84b..2579ef900b5 100644
--- a/compiler/testData/codegen/box/traits/withRequired/genericProperty.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/genericProperty.kt
@@ -2,7 +2,7 @@ abstract class Base {
abstract var s: T
}
-trait Trait : Base {
+interface Trait : Base {
var value : T
get() = s
set(value) { s = value }
diff --git a/compiler/testData/codegen/box/traits/withRequired/kt1936_2.kt b/compiler/testData/codegen/box/traits/withRequired/kt1936_2.kt
index d892033bb6b..8c17c464421 100644
--- a/compiler/testData/codegen/box/traits/withRequired/kt1936_2.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/kt1936_2.kt
@@ -2,7 +2,7 @@ open class MyClass(param : String) {
var propterty = param
}
-trait MyTrait : MyClass
+interface MyTrait : MyClass
{
fun foo() = propterty
}
diff --git a/compiler/testData/codegen/box/traits/withRequired/kt2963.kt b/compiler/testData/codegen/box/traits/withRequired/kt2963.kt
index 03b1d72120b..2d463906975 100644
--- a/compiler/testData/codegen/box/traits/withRequired/kt2963.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/kt2963.kt
@@ -1,6 +1,6 @@
open class Base
-trait Derived : Base {
+interface Derived : Base {
fun foo(): String {
return object {
fun bar() = baz(this@Derived)
diff --git a/compiler/testData/codegen/box/traits/withRequired/kt3413.kt b/compiler/testData/codegen/box/traits/withRequired/kt3413.kt
index 30cefd6fa2c..a27f370230f 100644
--- a/compiler/testData/codegen/box/traits/withRequired/kt3413.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/kt3413.kt
@@ -1,4 +1,4 @@
-trait Trait> : Enum {
+interface Trait> : Enum {
val value : String get() = name()
}
diff --git a/compiler/testData/codegen/box/traits/withRequired/kt3429.kt b/compiler/testData/codegen/box/traits/withRequired/kt3429.kt
index f865200c56c..18a55c90083 100644
--- a/compiler/testData/codegen/box/traits/withRequired/kt3429.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/kt3429.kt
@@ -4,7 +4,7 @@ open class Base {
}
}
-trait Trait: Base {
+interface Trait: Base {
override fun sayHello(): String {
return "OK"
}
diff --git a/compiler/testData/codegen/box/traits/withRequired/property.kt b/compiler/testData/codegen/box/traits/withRequired/property.kt
index 8aac0835791..f6945f36518 100644
--- a/compiler/testData/codegen/box/traits/withRequired/property.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/property.kt
@@ -2,7 +2,7 @@ open class Base {
var s = "Fail"
}
-trait Trait : Base {
+interface Trait : Base {
var value : String
get() = s
set(value) { s = value }
diff --git a/compiler/testData/codegen/box/traits/withRequired/propertyViaBridge.kt b/compiler/testData/codegen/box/traits/withRequired/propertyViaBridge.kt
index c07ce9735f9..96ed04b4aa6 100644
--- a/compiler/testData/codegen/box/traits/withRequired/propertyViaBridge.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/propertyViaBridge.kt
@@ -1,6 +1,6 @@
open class Base
-trait Trait : Base {
+interface Trait : Base {
private val value : String
get() = "OK"
diff --git a/compiler/testData/codegen/box/traits/withRequired/simple.kt b/compiler/testData/codegen/box/traits/withRequired/simple.kt
index 580498cbb68..2a4b89e189d 100644
--- a/compiler/testData/codegen/box/traits/withRequired/simple.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/simple.kt
@@ -1,4 +1,4 @@
-trait Trait : java.lang.Object {
+interface Trait : java.lang.Object {
fun foo(): String = "239 " + toString()
}
diff --git a/compiler/testData/codegen/box/traits/withRequired/super.kt b/compiler/testData/codegen/box/traits/withRequired/super.kt
index ac4d1f89cc3..064084c26ba 100644
--- a/compiler/testData/codegen/box/traits/withRequired/super.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/super.kt
@@ -4,7 +4,7 @@ open class Base {
}
}
-trait Derived : Base {
+interface Derived : Base {
override fun foo() : String {
//super.foo()
return "OK"
diff --git a/compiler/testData/codegen/box/traits/withRequired/superViaBridge.kt b/compiler/testData/codegen/box/traits/withRequired/superViaBridge.kt
index a00ac37c3d1..7bd8a552608 100644
--- a/compiler/testData/codegen/box/traits/withRequired/superViaBridge.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/superViaBridge.kt
@@ -3,7 +3,7 @@ open class Base {
open fun foo2() { }
}
-trait Derived : Base {
+interface Derived : Base {
override fun foo() {
object {
fun bar() {
diff --git a/compiler/testData/codegen/box/traits/withRequired/traitFuncCall.kt b/compiler/testData/codegen/box/traits/withRequired/traitFuncCall.kt
index e84d7931c56..b704ceb9e2d 100644
--- a/compiler/testData/codegen/box/traits/withRequired/traitFuncCall.kt
+++ b/compiler/testData/codegen/box/traits/withRequired/traitFuncCall.kt
@@ -3,7 +3,7 @@ open class Foo() {
}
-trait T: Foo {
+interface T: Foo {
public fun xyzzy(): String = o() + k()
public fun o(): String
}
diff --git a/compiler/testData/codegen/boxAgainstJava/notNullAssertions/Delegation.kt b/compiler/testData/codegen/boxAgainstJava/notNullAssertions/Delegation.kt
index 29b0e162a71..3dc0d38d534 100644
--- a/compiler/testData/codegen/boxAgainstJava/notNullAssertions/Delegation.kt
+++ b/compiler/testData/codegen/boxAgainstJava/notNullAssertions/Delegation.kt
@@ -1,4 +1,4 @@
-trait Tr {
+interface Tr {
fun foo(): String
}
diff --git a/compiler/testData/codegen/boxAgainstJava/property/fieldAccessFromExtensionInTraitImpl.kt b/compiler/testData/codegen/boxAgainstJava/property/fieldAccessFromExtensionInTraitImpl.kt
index ccd336f24d1..9b423f9a325 100644
--- a/compiler/testData/codegen/boxAgainstJava/property/fieldAccessFromExtensionInTraitImpl.kt
+++ b/compiler/testData/codegen/boxAgainstJava/property/fieldAccessFromExtensionInTraitImpl.kt
@@ -2,7 +2,7 @@
import fieldAccessFromExtensionInTraitImpl as D
-trait T {
+interface T {
fun Int.foo(d: D) = d.result!!
}
diff --git a/compiler/testData/codegen/boxInline/anonymousObject/capturedLambdaInInlineObject.2.kt b/compiler/testData/codegen/boxInline/anonymousObject/capturedLambdaInInlineObject.2.kt
index a3ff909d1c5..f54f014b2bf 100644
--- a/compiler/testData/codegen/boxInline/anonymousObject/capturedLambdaInInlineObject.2.kt
+++ b/compiler/testData/codegen/boxInline/anonymousObject/capturedLambdaInInlineObject.2.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun run(): T;
}
diff --git a/compiler/testData/codegen/boxInline/builders/builders.2.kt b/compiler/testData/codegen/boxInline/builders/builders.2.kt
index f2c29052b97..cb4bc6eac25 100644
--- a/compiler/testData/codegen/boxInline/builders/builders.2.kt
+++ b/compiler/testData/codegen/boxInline/builders/builders.2.kt
@@ -3,7 +3,7 @@ package builders
import java.util.ArrayList
import java.util.HashMap
-trait Element {
+interface Element {
fun render(builder: StringBuilder, indent: String)
override fun toString(): String {
diff --git a/compiler/testData/codegen/boxInline/builders/buildersAndLambdaCapturing.2.kt b/compiler/testData/codegen/boxInline/builders/buildersAndLambdaCapturing.2.kt
index c19b0284c3b..2fc26f262e8 100644
--- a/compiler/testData/codegen/boxInline/builders/buildersAndLambdaCapturing.2.kt
+++ b/compiler/testData/codegen/boxInline/builders/buildersAndLambdaCapturing.2.kt
@@ -3,7 +3,7 @@ package builders
import java.util.ArrayList
import java.util.HashMap
-trait Element {
+interface Element {
fun render(builder: StringBuilder, indent: String)
override fun toString(): String {
diff --git a/compiler/testData/codegen/boxInline/complex/use.2.kt b/compiler/testData/codegen/boxInline/complex/use.2.kt
index 0c74af1e7b2..c2a6ac78683 100644
--- a/compiler/testData/codegen/boxInline/complex/use.2.kt
+++ b/compiler/testData/codegen/boxInline/complex/use.2.kt
@@ -9,7 +9,7 @@ public class Output(val d: Data) : Closeable {
public fun doOutput(data: Int): Int = data
}
-public open trait Closeable {
+public open interface Closeable {
open public fun close() {}
}
diff --git a/compiler/testData/codegen/boxInline/complex/with.2.kt b/compiler/testData/codegen/boxInline/complex/with.2.kt
index 0684df6c177..a4ac07cfd41 100644
--- a/compiler/testData/codegen/boxInline/complex/with.2.kt
+++ b/compiler/testData/codegen/boxInline/complex/with.2.kt
@@ -11,7 +11,7 @@ public class Output(val d: Data) : Closeable {
public fun doOutput(data: Int): Int = data
}
-public open trait Closeable {
+public open interface Closeable {
open public fun close() {}
}
diff --git a/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/exceptionTable/exceptionInFinally.2.kt b/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/exceptionTable/exceptionInFinally.2.kt
index 8e0745401c9..436c9974338 100644
--- a/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/exceptionTable/exceptionInFinally.2.kt
+++ b/compiler/testData/codegen/boxInline/nonLocalReturns/tryFinally/exceptionTable/exceptionInFinally.2.kt
@@ -1,6 +1,6 @@
package test
-public trait MCloseable {
+public interface MCloseable {
public open fun close()
}
diff --git a/compiler/testData/codegen/boxInline/trait/trait.2.kt b/compiler/testData/codegen/boxInline/trait/trait.2.kt
index d7a9b4e33c1..ed56b295051 100644
--- a/compiler/testData/codegen/boxInline/trait/trait.2.kt
+++ b/compiler/testData/codegen/boxInline/trait/trait.2.kt
@@ -1,6 +1,6 @@
package test
-trait InlineTrait {
+interface InlineTrait {
inline final fun finalInline(s: () -> String): String {
return s()
diff --git a/compiler/testData/codegen/boxWithJava/builtinStubMethods/substitutedIterable/substitutedIterable.kt b/compiler/testData/codegen/boxWithJava/builtinStubMethods/substitutedIterable/substitutedIterable.kt
index f1812b3e4f7..0a6c159ccb2 100644
--- a/compiler/testData/codegen/boxWithJava/builtinStubMethods/substitutedIterable/substitutedIterable.kt
+++ b/compiler/testData/codegen/boxWithJava/builtinStubMethods/substitutedIterable/substitutedIterable.kt
@@ -1,4 +1,4 @@
-trait MyIterable : Iterable
+interface MyIterable : Iterable
class E : RuntimeException()
fun foo(): MyIterable = throw E()
diff --git a/compiler/testData/codegen/boxWithJava/properties/classObjectProperties/Test.java b/compiler/testData/codegen/boxWithJava/properties/classObjectProperties/Test.java
index eef03d83106..28cf20463a5 100644
--- a/compiler/testData/codegen/boxWithJava/properties/classObjectProperties/Test.java
+++ b/compiler/testData/codegen/boxWithJava/properties/classObjectProperties/Test.java
@@ -6,7 +6,7 @@ class Test {
if (!s.equals("Klass")) throw new AssertionError("Fail class: " + s);
s = Trait.NAME;
- if (!s.equals("Trait")) throw new AssertionError("Fail trait: " + s);
+ if (!s.equals("Trait")) throw new AssertionError("Fail interface: " + s);
s = Enoom.NAME;
if (!s.equals("Enoom")) throw new AssertionError("Fail enum: " + s);
diff --git a/compiler/testData/codegen/boxWithJava/properties/classObjectProperties/classObjectProperties.kt b/compiler/testData/codegen/boxWithJava/properties/classObjectProperties/classObjectProperties.kt
index 00c287d105d..395e96670e0 100644
--- a/compiler/testData/codegen/boxWithJava/properties/classObjectProperties/classObjectProperties.kt
+++ b/compiler/testData/codegen/boxWithJava/properties/classObjectProperties/classObjectProperties.kt
@@ -4,7 +4,7 @@ class Klass {
}
}
-trait Trait {
+interface Trait {
companion object {
val NAME = "Trait"
}
diff --git a/compiler/testData/codegen/boxWithJava/trait/interfaceInheritance.kt b/compiler/testData/codegen/boxWithJava/trait/interfaceInheritance.kt
index 7e1dd4e1527..bceff8b3b05 100644
--- a/compiler/testData/codegen/boxWithJava/trait/interfaceInheritance.kt
+++ b/compiler/testData/codegen/boxWithJava/trait/interfaceInheritance.kt
@@ -1,4 +1,4 @@
-trait A : MyInt {
+interface A : MyInt {
override public fun test(): String? {
return "OK"
}
diff --git a/compiler/testData/codegen/boxWithStdlib/arrays/stdlib.kt b/compiler/testData/codegen/boxWithStdlib/arrays/stdlib.kt
index 58b5bcbb584..e7ff20e0b62 100644
--- a/compiler/testData/codegen/boxWithStdlib/arrays/stdlib.kt
+++ b/compiler/testData/codegen/boxWithStdlib/arrays/stdlib.kt
@@ -1,8 +1,8 @@
-trait ISized {
+interface ISized {
val size : Int
}
-trait javaUtilIterator : Iterator {
+interface javaUtilIterator : Iterator {
fun remove() : Unit {
throw UnsupportedOperationException()
}
@@ -16,13 +16,13 @@ class MyIterator(val array : ReadOnlyArray) : javaUtilIterator {
override fun next() : T = array.get(index++)
}
-trait ReadOnlyArray : ISized, Iterable {
+interface ReadOnlyArray : ISized, Iterable {
fun get(index : Int) : T
override fun iterator() : Iterator = MyIterator(this)
}
-trait WriteOnlyArray : ISized {
+interface WriteOnlyArray : ISized {
fun set(index : Int, value : T) : Unit
fun set(from: Int, count: Int, value: T) {
diff --git a/compiler/testData/codegen/boxWithStdlib/callableReference/function/local/enumExtendsTrait.kt b/compiler/testData/codegen/boxWithStdlib/callableReference/function/local/enumExtendsTrait.kt
index 36954fb8250..5b28434e19c 100644
--- a/compiler/testData/codegen/boxWithStdlib/callableReference/function/local/enumExtendsTrait.kt
+++ b/compiler/testData/codegen/boxWithStdlib/callableReference/function/local/enumExtendsTrait.kt
@@ -1,4 +1,4 @@
-trait Named {
+interface Named {
fun name(): String
}
diff --git a/compiler/testData/codegen/boxWithStdlib/callableReference/function/traitImplMethodWithClassReceiver.kt b/compiler/testData/codegen/boxWithStdlib/callableReference/function/traitImplMethodWithClassReceiver.kt
index 27f8a407fb9..b47561d9d03 100644
--- a/compiler/testData/codegen/boxWithStdlib/callableReference/function/traitImplMethodWithClassReceiver.kt
+++ b/compiler/testData/codegen/boxWithStdlib/callableReference/function/traitImplMethodWithClassReceiver.kt
@@ -1,4 +1,4 @@
-trait T {
+interface T {
fun foo() = "OK"
}
diff --git a/compiler/testData/codegen/boxWithStdlib/callableReference/function/traitMember.kt b/compiler/testData/codegen/boxWithStdlib/callableReference/function/traitMember.kt
index 8b278fb0ebb..619220ff65f 100644
--- a/compiler/testData/codegen/boxWithStdlib/callableReference/function/traitMember.kt
+++ b/compiler/testData/codegen/boxWithStdlib/callableReference/function/traitMember.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(): String
}
diff --git a/compiler/testData/codegen/boxWithStdlib/dataClasses/tostring/alreadyInherited.kt b/compiler/testData/codegen/boxWithStdlib/dataClasses/tostring/alreadyInherited.kt
index b91111255d8..52cefe0fa66 100644
--- a/compiler/testData/codegen/boxWithStdlib/dataClasses/tostring/alreadyInherited.kt
+++ b/compiler/testData/codegen/boxWithStdlib/dataClasses/tostring/alreadyInherited.kt
@@ -1,4 +1,4 @@
-trait SuperTrait {
+interface SuperTrait {
override fun toString(): String = "!"
}
diff --git a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1202.kt b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1202.kt
index deaa57f525c..b95c0cb3fd9 100644
--- a/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1202.kt
+++ b/compiler/testData/codegen/boxWithStdlib/fullJdk/regressions/kt1202.kt
@@ -2,7 +2,7 @@ package testeval
import java.util.*
-trait Expression
+interface Expression
class Num(val value : Int) : Expression
class Sum(val left : Expression, val right : Expression) : Expression
class Mult(val left : Expression, val right : Expression) : Expression
@@ -16,7 +16,7 @@ fun eval(e : Expression) : Int {
}
}
-trait ParseResult {
+interface ParseResult {
val success : Boolean
val value : T
}
diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/anonymousObjectInInlinedLambda.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/anonymousObjectInInlinedLambda.kt
index 6744ff747e3..a1d3c1b512b 100644
--- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/anonymousObjectInInlinedLambda.kt
+++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/anonymousObjectInInlinedLambda.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun f(): String
}
diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6368.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6368.kt
index 92ed2f45efe..16d226f3c0d 100644
--- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6368.kt
+++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/kt6368.kt
@@ -1,7 +1,7 @@
import kotlin.properties.Delegates
import java.util.HashMap
-trait R {
+interface R {
fun result(): String
}
diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectExpression.kt b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectExpression.kt
index dc13bfe9571..0e04ffaa04b 100644
--- a/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectExpression.kt
+++ b/compiler/testData/codegen/boxWithStdlib/reflection/enclosing/lambdaInObjectExpression.kt
@@ -1,4 +1,4 @@
-trait C {
+interface C {
val a: Any
}
diff --git a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt5112.kt b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt5112.kt
index 4be92ec9f51..c1a8e0d47f4 100644
--- a/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt5112.kt
+++ b/compiler/testData/codegen/boxWithStdlib/reflection/genericSignature/kt5112.kt
@@ -4,7 +4,7 @@ class G(val s: T) {
}
-public trait ErrorsJvmTrait {
+public interface ErrorsJvmTrait {
companion object {
public val param : G = G("STRING")
}
diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/Kt1149.kt b/compiler/testData/codegen/boxWithStdlib/regressions/Kt1149.kt
index 1abb4b7ec6f..7738799710e 100644
--- a/compiler/testData/codegen/boxWithStdlib/regressions/Kt1149.kt
+++ b/compiler/testData/codegen/boxWithStdlib/regressions/Kt1149.kt
@@ -3,7 +3,7 @@ package test.regressions.kt1149
import java.util.ArrayList
import kotlin.util.*
-public trait SomeTrait {
+public interface SomeTrait {
fun foo()
}
diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/kt4142.kt b/compiler/testData/codegen/boxWithStdlib/regressions/kt4142.kt
index e02b05f37bb..d7fe122fda7 100644
--- a/compiler/testData/codegen/boxWithStdlib/regressions/kt4142.kt
+++ b/compiler/testData/codegen/boxWithStdlib/regressions/kt4142.kt
@@ -3,7 +3,7 @@ open class B {
get() = "OK"
}
-trait A {
+interface A {
val name: String
}
diff --git a/compiler/testData/codegen/boxWithStdlib/regressions/objectCaptureOuterConstructorProperty.kt b/compiler/testData/codegen/boxWithStdlib/regressions/objectCaptureOuterConstructorProperty.kt
index c25d8948d60..dd3315896ec 100644
--- a/compiler/testData/codegen/boxWithStdlib/regressions/objectCaptureOuterConstructorProperty.kt
+++ b/compiler/testData/codegen/boxWithStdlib/regressions/objectCaptureOuterConstructorProperty.kt
@@ -1,6 +1,6 @@
import kotlin.support.*
-trait Stream {
+interface Stream {
fun iterator(): Iterator
}
diff --git a/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectNoPropagate.kt b/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectNoPropagate.kt
index b405666b768..b9ff3a1cd9a 100644
--- a/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectNoPropagate.kt
+++ b/compiler/testData/codegen/boxWithStdlib/reified/anonymousObjectNoPropagate.kt
@@ -1,6 +1,6 @@
import kotlin.test.assertEquals
-trait A {
+interface A {
fun f1(): String
fun f2(): String
fun f3(): String
diff --git a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObject.kt b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObject.kt
index 339a09dd4a4..610af457377 100644
--- a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObject.kt
+++ b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObject.kt
@@ -2,7 +2,7 @@ import kotlin.test.assertEquals
fun foo(block: () -> String) = block()
-trait A {
+interface A {
fun f(): String
fun g(): String
}
diff --git a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObjectWithinReified.kt b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObjectWithinReified.kt
index 94335af2b62..0796b64399e 100644
--- a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObjectWithinReified.kt
+++ b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineFunOfObjectWithinReified.kt
@@ -6,7 +6,7 @@ inline fun className(): String = javaClass().getName()
inline fun lambdaShouldBeReified(): String = foo { className() }
-trait A {
+interface A {
fun f(): String
fun g(): String
}
diff --git a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineIntoNonInlineableLambda.kt b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineIntoNonInlineableLambda.kt
index ce25ba54f75..542b658441a 100644
--- a/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineIntoNonInlineableLambda.kt
+++ b/compiler/testData/codegen/boxWithStdlib/reified/reifiedInlineIntoNonInlineableLambda.kt
@@ -4,7 +4,7 @@ fun foo(block: () -> String) = block()
inline fun className(): String = javaClass().getName()
-trait A {
+interface A {
fun f(): String
fun g(): String
}
diff --git a/compiler/testData/codegen/bytecodeText/bridgeForFakeOverride.kt b/compiler/testData/codegen/bytecodeText/bridgeForFakeOverride.kt
index 1b9a31ed573..2f481c74fc3 100644
--- a/compiler/testData/codegen/bytecodeText/bridgeForFakeOverride.kt
+++ b/compiler/testData/codegen/bytecodeText/bridgeForFakeOverride.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo(): Any
}
diff --git a/compiler/testData/codegen/bytecodeText/traitImplGeneratedOnce.kt b/compiler/testData/codegen/bytecodeText/traitImplGeneratedOnce.kt
index 51ce275d99e..234a276c49d 100644
--- a/compiler/testData/codegen/bytecodeText/traitImplGeneratedOnce.kt
+++ b/compiler/testData/codegen/bytecodeText/traitImplGeneratedOnce.kt
@@ -1,4 +1,4 @@
-trait A {
+interface A {
fun foo() = 42
}
diff --git a/compiler/testData/codegen/classes/delegationToVal.kt b/compiler/testData/codegen/classes/delegationToVal.kt
index ec6242f5d16..0a4558ae4b7 100644
--- a/compiler/testData/codegen/classes/delegationToVal.kt
+++ b/compiler/testData/codegen/classes/delegationToVal.kt
@@ -1,4 +1,4 @@
-trait IActing {
+interface IActing {
fun act(): String
}
diff --git a/compiler/testData/codegen/innerClassInfo/innerAccessFlags.kt b/compiler/testData/codegen/innerClassInfo/innerAccessFlags.kt
index b902284e2b8..a96744e9995 100644
--- a/compiler/testData/codegen/innerClassInfo/innerAccessFlags.kt
+++ b/compiler/testData/codegen/innerClassInfo/innerAccessFlags.kt
@@ -2,7 +2,7 @@ class A {
// Kind
annotation class Annotation
enum class Enum
- trait Trait
+ interface Trait
// Modality
open class OpenStaticClass
diff --git a/compiler/testData/codegen/java8/boxWithJava/defaultMethodCallViaTrait/defaultMethodCallViaTrait.kt b/compiler/testData/codegen/java8/boxWithJava/defaultMethodCallViaTrait/defaultMethodCallViaTrait.kt
index 77c2a40cf45..e7ba10889c2 100644
--- a/compiler/testData/codegen/java8/boxWithJava/defaultMethodCallViaTrait/defaultMethodCallViaTrait.kt
+++ b/compiler/testData/codegen/java8/boxWithJava/defaultMethodCallViaTrait/defaultMethodCallViaTrait.kt
@@ -1,4 +1,4 @@
-trait TestTrait : Simple {}
+interface TestTrait : Simple {}
class Test : TestTrait {}
fun box(): String {
diff --git a/compiler/testData/codegen/notNullAssertions/AssertionChecker.kt b/compiler/testData/codegen/notNullAssertions/AssertionChecker.kt
index 40eb76742af..d3643218d1d 100644
--- a/compiler/testData/codegen/notNullAssertions/AssertionChecker.kt
+++ b/compiler/testData/codegen/notNullAssertions/AssertionChecker.kt
@@ -11,7 +11,7 @@ class AssertionChecker(val illegalStateExpected: Boolean) {
}
-trait Tr {
+interface Tr {
fun foo(): String
}
diff --git a/compiler/testData/codegen/properties/syntheticMethod/inTrait.kt b/compiler/testData/codegen/properties/syntheticMethod/inTrait.kt
index 4baa7786d3b..7f11e0e4012 100644
--- a/compiler/testData/codegen/properties/syntheticMethod/inTrait.kt
+++ b/compiler/testData/codegen/properties/syntheticMethod/inTrait.kt
@@ -2,6 +2,6 @@ import java.lang.annotation.*
Retention(RetentionPolicy.RUNTIME) annotation class SomeAnnotation(val value: String)
-trait T {
+interface T {
[SomeAnnotation("OK")] val property: Int
}
diff --git a/compiler/testData/codegen/regressions/kt297.kt b/compiler/testData/codegen/regressions/kt297.kt
index 0a6ad8f82a5..169d061c6de 100644
--- a/compiler/testData/codegen/regressions/kt297.kt
+++ b/compiler/testData/codegen/regressions/kt297.kt
@@ -1,4 +1,4 @@
-// KT-297 Overload resolution ambiguity with required in trait
-trait ALE : java.util.ArrayList {
+// KT-297 Overload resolution ambiguity with required in interface
+interface ALE : java.util.ArrayList {
fun getOrValue(index: Int, value : T) : T = if(index >= 0 && index < size()) get(index) else value
}
\ No newline at end of file
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/Delegation.kt b/compiler/testData/compileJavaAgainstKotlin/method/Delegation.kt
index 81c402f355b..880b3c9ad0f 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/Delegation.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/Delegation.kt
@@ -1,6 +1,6 @@
package test
-trait Trait {
+interface Trait {
fun foo()
val bar: Int
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/TraitImpl.kt b/compiler/testData/compileJavaAgainstKotlin/method/TraitImpl.kt
index 8f12a0bf590..14d5affe430 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/TraitImpl.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/TraitImpl.kt
@@ -1,6 +1,6 @@
package test
-trait Trait {
+interface Trait {
fun simple() {
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/ByteOverridesObject.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/ByteOverridesObject.kt
index 230e0d16013..ca45627f88a 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/ByteOverridesObject.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/ByteOverridesObject.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun foo(): T
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CallFinalNotInSubclass.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CallFinalNotInSubclass.kt
index 918943a1ab1..db977673289 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CallFinalNotInSubclass.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CallFinalNotInSubclass.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun foo(): T
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CallNotInSubclass.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CallNotInSubclass.kt
index 3bba95749b3..9e76fbf5f05 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CallNotInSubclass.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CallNotInSubclass.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun foo(): T
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CovariantReturnTypeOverride.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CovariantReturnTypeOverride.kt
index 795637eaa7b..edb53697a90 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CovariantReturnTypeOverride.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/CovariantReturnTypeOverride.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun foo(): Any
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/FinalOverride.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/FinalOverride.kt
index f2f8226a9bc..d05e0c28918 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/FinalOverride.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/FinalOverride.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun foo(): T
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesComparable.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesComparable.kt
index 227271d3d74..4825976da81 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesComparable.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesComparable.kt
@@ -1,6 +1,6 @@
package test
-trait A> {
+interface A> {
fun foo(): T
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesNumber.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesNumber.kt
index 69d6c4796a4..4e59e10e679 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesNumber.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesNumber.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun foo(): T
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesObject.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesObject.kt
index 185be0adc22..97b8a7540f1 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesObject.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/IntOverridesObject.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun foo(): T
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/ManyClassesHierarchy.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/ManyClassesHierarchy.kt
index 825917181d6..404576a1c11 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/ManyClassesHierarchy.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/ManyClassesHierarchy.kt
@@ -1,10 +1,10 @@
package test
-trait A {
+interface A {
fun foo(): T
}
-trait B : A
+interface B : A
abstract class C : B
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/NullableIntOverridesObject.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/NullableIntOverridesObject.kt
index 816a6c0b288..642fdaf23df 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/NullableIntOverridesObject.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/NullableIntOverridesObject.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun foo(): T
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/OverrideInJava.kt b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/OverrideInJava.kt
index d1e5e86a8ef..8438becf723 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/OverrideInJava.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/primitiveOverride/OverrideInJava.kt
@@ -1,6 +1,6 @@
package test
-trait A {
+interface A {
fun foo(): T
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/throws/Delegation.kt b/compiler/testData/compileJavaAgainstKotlin/method/throws/Delegation.kt
index 6d11ab9149d..9399efe1aa5 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/throws/Delegation.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/throws/Delegation.kt
@@ -3,7 +3,7 @@ package test
class E1: Exception()
class E2: Exception()
-trait Trait {
+interface Trait {
throws()
fun none()
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/throws/GenericSubstitution.kt b/compiler/testData/compileJavaAgainstKotlin/method/throws/GenericSubstitution.kt
index 27154abdc6e..befd95233be 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/throws/GenericSubstitution.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/throws/GenericSubstitution.kt
@@ -2,7 +2,7 @@ package test
class E1: Exception()
-trait Base {
+interface Base {
throws(E1::class)
fun one(t: T) {}
}
diff --git a/compiler/testData/compileJavaAgainstKotlin/method/throws/TraitMembers.kt b/compiler/testData/compileJavaAgainstKotlin/method/throws/TraitMembers.kt
index 58f97b762dc..cb242d3c5c7 100644
--- a/compiler/testData/compileJavaAgainstKotlin/method/throws/TraitMembers.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/method/throws/TraitMembers.kt
@@ -3,7 +3,7 @@ package test
class E1: Exception()
class E2: Exception()
-trait Trait {
+interface Trait {
throws()
fun none() {}
diff --git a/compiler/testData/compileJavaAgainstKotlin/staticFields/AnnotationTrait.kt b/compiler/testData/compileJavaAgainstKotlin/staticFields/AnnotationTrait.kt
index 9c0944a7948..06aed71a05a 100644
--- a/compiler/testData/compileJavaAgainstKotlin/staticFields/AnnotationTrait.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/staticFields/AnnotationTrait.kt
@@ -8,7 +8,7 @@ annotation class ALong(val value: Long)
annotation class ADouble(val value: Double)
annotation class AFloat(val value: Float)
-trait Test {
+interface Test {
companion object {
val vstring: String = "Test"
diff --git a/compiler/testData/compileJavaAgainstKotlin/staticFields/staticTraitProperty.kt b/compiler/testData/compileJavaAgainstKotlin/staticFields/staticTraitProperty.kt
index 9d8b9a15fbe..b1958bb1156 100644
--- a/compiler/testData/compileJavaAgainstKotlin/staticFields/staticTraitProperty.kt
+++ b/compiler/testData/compileJavaAgainstKotlin/staticFields/staticTraitProperty.kt
@@ -1,6 +1,6 @@
package test
-trait Test {
+interface Test {
companion object {
public val valProp: Int = 10
diff --git a/compiler/testData/compileKotlinAgainstCustomBinaries/noWarningsOnJavaKotlinInheritance/noWarningsOnJavaKotlinInheritance.kt b/compiler/testData/compileKotlinAgainstCustomBinaries/noWarningsOnJavaKotlinInheritance/noWarningsOnJavaKotlinInheritance.kt
index 11f0f17de03..bc617c7f74c 100644
--- a/compiler/testData/compileKotlinAgainstCustomBinaries/noWarningsOnJavaKotlinInheritance/noWarningsOnJavaKotlinInheritance.kt
+++ b/compiler/testData/compileKotlinAgainstCustomBinaries/noWarningsOnJavaKotlinInheritance/noWarningsOnJavaKotlinInheritance.kt
@@ -7,7 +7,7 @@ class SimpleSubclass : JavaInterface {
// Class extends both Java and Kotlin traits. Checks that there's no DIFFERENT_NAMES_FOR_THE_SAME_PARAMETER_IN_SUPERTYPES warning
-trait KotlinTrait {
+interface KotlinTrait {
public fun foo(someOtherName: Int) {}
}
diff --git a/compiler/testData/compileKotlinAgainstKotlin/AnnotationInTrait.A.kt b/compiler/testData/compileKotlinAgainstKotlin/AnnotationInTrait.A.kt
index dc872ab7fd2..a04ee6dda50 100644
--- a/compiler/testData/compileKotlinAgainstKotlin/AnnotationInTrait.A.kt
+++ b/compiler/testData/compileKotlinAgainstKotlin/AnnotationInTrait.A.kt
@@ -5,7 +5,7 @@ import java.lang.annotation.*
Retention(RetentionPolicy.RUNTIME)
annotation class Ann
-trait Tr {
+interface Tr {
Ann
fun foo() {}
}
\ No newline at end of file
diff --git a/compiler/testData/compileKotlinAgainstKotlin/RecursiveGeneric.A.kt b/compiler/testData/compileKotlinAgainstKotlin/RecursiveGeneric.A.kt
index 3c7973fdbdc..15e0b1766fb 100644
--- a/compiler/testData/compileKotlinAgainstKotlin/RecursiveGeneric.A.kt
+++ b/compiler/testData/compileKotlinAgainstKotlin/RecursiveGeneric.A.kt
@@ -1,9 +1,9 @@
package a
-trait Rec> {
+interface Rec> {
fun t(): T
}
-trait Super {
+interface Super {
fun foo(p: Rec<*, *>) = p.t()
}
\ No newline at end of file
diff --git a/compiler/testData/constraintSystem/declarations/declarations.kt b/compiler/testData/constraintSystem/declarations/declarations.kt
index d4dc77f5df6..832e99dd7f9 100644
--- a/compiler/testData/constraintSystem/declarations/declarations.kt
+++ b/compiler/testData/constraintSystem/declarations/declarations.kt
@@ -1,10 +1,10 @@
fun foo() = 42
-trait A
-trait B : A
-trait C : B
+interface A
+interface B : A
+interface C : B
-trait Consumer
-trait Producer
+interface Consumer
+interface Producer
-trait My
\ No newline at end of file
+interface My