Migration to expect/actual: fix multiplatform integration tests

This commit is contained in:
Mikhail Glukhikh
2017-09-15 10:44:43 +03:00
parent 27615209ed
commit 85d6a4d1af
65 changed files with 394 additions and 394 deletions
+3 -3
View File
@@ -1,9 +1,9 @@
header class Foo {
expect class Foo {
fun f(s: String)
fun f(a: Any)
}
header fun g(s: String)
expect fun g(s: String)
header fun g(a: Any)
expect fun g(a: Any)
+3 -3
View File
@@ -1,5 +1,5 @@
impl class Foo {
impl fun f(s: String) {}
actual class Foo {
actual fun f(s: String) {}
}
impl fun g(a: Any) {}
actual fun g(a: Any) {}
+7 -7
View File
@@ -7,16 +7,16 @@ Exit code: COMPILATION_ERROR
Output:
compiler/testData/multiplatform/missingOverload/common.kt:7:1: error: 'header' function 'g' has no implementation in module
The following declaration is incompatible because parameter types are different:
public impl fun g(a: Any): Unit
public actual fun g(a: Any): Unit
header fun g(s: String)
expect fun g(s: String)
^
compiler/testData/multiplatform/missingOverload/jvm.kt:1:12: error: 'impl' class 'Foo' has no implementation of 'header' class members:
compiler/testData/multiplatform/missingOverload/jvm.kt:1:14: error: 'impl' class 'Foo' has no implementation of 'header' class members:
public final header fun f(a: Any): Unit
public final expect fun f(a: Any): Unit
The following declaration is incompatible because parameter types are different:
public final impl fun f(s: String): Unit
public final actual fun f(s: String): Unit
impl class Foo {
^
actual class Foo {
^