Migration to expect/actual: fix multiplatform integration tests
This commit is contained in:
+16
-16
@@ -1,22 +1,22 @@
|
||||
header class PClass
|
||||
header interface PInterface
|
||||
header object PObject
|
||||
header enum class PEnumClass
|
||||
header annotation class PAnnotationClass
|
||||
expect class PClass
|
||||
expect interface PInterface
|
||||
expect object PObject
|
||||
expect enum class PEnumClass
|
||||
expect annotation class PAnnotationClass
|
||||
|
||||
internal header object InternalObject
|
||||
public header object PublicObject
|
||||
private header object PrivateObject
|
||||
internal expect object InternalObject
|
||||
public expect object PublicObject
|
||||
private expect object PrivateObject
|
||||
|
||||
open header class OpenClass
|
||||
abstract header class AbstractClass
|
||||
final header class FinalClass
|
||||
open expect class OpenClass
|
||||
abstract expect class AbstractClass
|
||||
final expect class FinalClass
|
||||
|
||||
header class C1<A>
|
||||
header class C2<B>
|
||||
header class C3<D, E : D>
|
||||
expect class C1<A>
|
||||
expect class C2<B>
|
||||
expect class C3<D, E : D>
|
||||
|
||||
header class C4<F>
|
||||
expect class C4<F>
|
||||
|
||||
|
||||
header abstract class ExtendsNumber : Number
|
||||
expect abstract class ExtendsNumber : Number
|
||||
|
||||
+16
-16
@@ -1,22 +1,22 @@
|
||||
impl interface PClass
|
||||
impl object PInterface
|
||||
impl enum class PObject
|
||||
impl annotation class PEnumClass
|
||||
impl class PAnnotationClass
|
||||
actual interface PClass
|
||||
actual object PInterface
|
||||
actual enum class PObject
|
||||
actual annotation class PEnumClass
|
||||
actual class PAnnotationClass
|
||||
|
||||
private impl object InternalObject
|
||||
internal impl object PublicObject
|
||||
public impl object PrivateObject
|
||||
private actual object InternalObject
|
||||
internal actual object PublicObject
|
||||
public actual object PrivateObject
|
||||
|
||||
final impl class OpenClass
|
||||
open impl class AbstractClass
|
||||
abstract impl class FinalClass
|
||||
final actual class OpenClass
|
||||
open actual class AbstractClass
|
||||
abstract actual class FinalClass
|
||||
|
||||
impl class C1<A, Extra>
|
||||
impl class C2<out B>
|
||||
impl class C3<D, E : D?>
|
||||
actual class C1<A, Extra>
|
||||
actual class C2<out B>
|
||||
actual class C3<D, E : D?>
|
||||
|
||||
impl typealias C4<F> = C4Impl<F>
|
||||
actual typealias C4<F> = C4Impl<F>
|
||||
class C4Impl<F : Number>
|
||||
|
||||
impl abstract class ExtendsNumber : Any()
|
||||
actual abstract class ExtendsNumber : Any()
|
||||
|
||||
+72
-72
@@ -5,87 +5,87 @@ Output:
|
||||
-- JVM --
|
||||
Exit code: COMPILATION_ERROR
|
||||
Output:
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:1:16: error: 'impl' interface 'PClass' has no corresponding 'header' declaration
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:1:18: error: 'impl' interface 'PClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because class kinds are different (class, interface, object, enum, annotation):
|
||||
public final header class PClass
|
||||
public final expect class PClass
|
||||
|
||||
impl interface PClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:2:6: error: 'impl' object 'PInterface' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because class kinds are different (class, interface, object, enum, annotation):
|
||||
public header interface PInterface
|
||||
|
||||
impl object PInterface
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:3:17: error: 'impl' enum class 'PObject' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because class kinds are different (class, interface, object, enum, annotation):
|
||||
public header object PObject
|
||||
|
||||
impl enum class PObject
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:4:23: error: 'impl' annotation class 'PEnumClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because class kinds are different (class, interface, object, enum, annotation):
|
||||
public final header enum class PEnumClass : Enum<PEnumClass>
|
||||
|
||||
impl annotation class PEnumClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:5:12: error: 'impl' class 'PAnnotationClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because class kinds are different (class, interface, object, enum, annotation):
|
||||
public final header annotation class PAnnotationClass : Annotation
|
||||
|
||||
impl class PAnnotationClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:7:14: error: 'impl' object 'InternalObject' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because visibility is different:
|
||||
internal header object InternalObject
|
||||
|
||||
private impl object InternalObject
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:8:15: error: 'impl' object 'PublicObject' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because visibility is different:
|
||||
public header object PublicObject
|
||||
|
||||
internal impl object PublicObject
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:9:13: error: 'impl' object 'PrivateObject' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because visibility is different:
|
||||
private header object PrivateObject
|
||||
|
||||
public impl object PrivateObject
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:11:18: error: 'impl' class 'OpenClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because modality is different:
|
||||
public open header class OpenClass
|
||||
|
||||
final impl class OpenClass
|
||||
actual interface PClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:12:17: error: 'impl' class 'AbstractClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because modality is different:
|
||||
public abstract header class AbstractClass
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:2:8: error: 'impl' object 'PInterface' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because class kinds are different (class, interface, object, enum, annotation):
|
||||
public expect interface PInterface
|
||||
|
||||
open impl class AbstractClass
|
||||
actual object PInterface
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:3:19: error: 'impl' enum class 'PObject' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because class kinds are different (class, interface, object, enum, annotation):
|
||||
public expect object PObject
|
||||
|
||||
actual enum class PObject
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:4:25: error: 'impl' annotation class 'PEnumClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because class kinds are different (class, interface, object, enum, annotation):
|
||||
public final expect enum class PEnumClass : Enum<PEnumClass>
|
||||
|
||||
actual annotation class PEnumClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:5:14: error: 'impl' class 'PAnnotationClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because class kinds are different (class, interface, object, enum, annotation):
|
||||
public final expect annotation class PAnnotationClass : Annotation
|
||||
|
||||
actual class PAnnotationClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:7:16: error: 'impl' object 'InternalObject' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because visibility is different:
|
||||
internal expect object InternalObject
|
||||
|
||||
private actual object InternalObject
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:8:17: error: 'impl' object 'PublicObject' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because visibility is different:
|
||||
public expect object PublicObject
|
||||
|
||||
internal actual object PublicObject
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:13:21: error: 'impl' class 'FinalClass' has no corresponding 'header' declaration
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:9:15: error: 'impl' object 'PrivateObject' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because visibility is different:
|
||||
private expect object PrivateObject
|
||||
|
||||
public actual object PrivateObject
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:11:20: error: 'impl' class 'OpenClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because modality is different:
|
||||
public final header class FinalClass
|
||||
public open expect class OpenClass
|
||||
|
||||
abstract impl class FinalClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:15:12: error: 'impl' class 'C1' has no corresponding 'header' declaration
|
||||
final actual class OpenClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:12:19: error: 'impl' class 'AbstractClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because modality is different:
|
||||
public abstract expect class AbstractClass
|
||||
|
||||
open actual class AbstractClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:13:23: error: 'impl' class 'FinalClass' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because modality is different:
|
||||
public final expect class FinalClass
|
||||
|
||||
abstract actual class FinalClass
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:15:14: error: 'impl' class 'C1' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because number of type parameters is different:
|
||||
public final header class C1<A>
|
||||
public final expect class C1<A>
|
||||
|
||||
impl class C1<A, Extra>
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:16:12: error: 'impl' class 'C2' has no corresponding 'header' declaration
|
||||
actual class C1<A, Extra>
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:16:14: error: 'impl' class 'C2' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because declaration-site variances of type parameters are different:
|
||||
public final header class C2<B>
|
||||
public final expect class C2<B>
|
||||
|
||||
impl class C2<out B>
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:22:21: error: 'impl' class 'ExtendsNumber' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because some supertypes are missing in the implementation:
|
||||
public abstract header class ExtendsNumber : Number
|
||||
actual class C2<out B>
|
||||
^
|
||||
compiler/testData/multiplatform/incompatibleClasses/jvm.kt:22:23: error: 'impl' class 'ExtendsNumber' has no corresponding 'header' declaration
|
||||
The following declaration is incompatible because some supertypes are missing in the actual declaration:
|
||||
public abstract expect class ExtendsNumber : Number
|
||||
|
||||
impl abstract class ExtendsNumber : Any()
|
||||
^
|
||||
actual abstract class ExtendsNumber : Any()
|
||||
^
|
||||
|
||||
Reference in New Issue
Block a user