Replace @native with external in tests
This commit is contained in:
@@ -14,7 +14,7 @@ class B : A() {
|
||||
}
|
||||
}
|
||||
|
||||
@native fun bar(a: A)
|
||||
external fun bar(a: A)
|
||||
|
||||
fun box(): String {
|
||||
bar(A())
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
// FILE: castToNativeClassChecked.kt
|
||||
@native abstract class S() {
|
||||
external abstract class S() {
|
||||
abstract fun foo(): String
|
||||
}
|
||||
|
||||
@native class A(x: String) {
|
||||
external class A(x: String) {
|
||||
fun foo(): String = definedExternally
|
||||
}
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
// FILE: castToNativeInterface.kt
|
||||
@native interface I {
|
||||
external interface I {
|
||||
fun foo(): String
|
||||
}
|
||||
|
||||
@native class A(x: String) : I {
|
||||
external class A(x: String) : I {
|
||||
override fun foo(): String = definedExternally
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@native interface I {
|
||||
external interface I {
|
||||
fun foo(): String
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@native interface I {
|
||||
external interface I {
|
||||
fun foo(): String
|
||||
}
|
||||
|
||||
|
||||
+3
-3
@@ -1,5 +1,5 @@
|
||||
// FILE: castToTypeParamBoundedByNativeInterface.kt
|
||||
@native interface I {
|
||||
external interface I {
|
||||
fun foo(): String
|
||||
}
|
||||
|
||||
@@ -7,9 +7,9 @@ interface J {
|
||||
fun bar(): String
|
||||
}
|
||||
|
||||
@native abstract class B() : I
|
||||
external abstract class B() : I
|
||||
|
||||
@native class A(x: String) : B() {
|
||||
external class A(x: String) : B {
|
||||
override fun foo(): String = definedExternally
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -1,8 +1,8 @@
|
||||
data class A(val number: Int)
|
||||
|
||||
@native fun foo(first: A, second: A): Boolean
|
||||
external fun foo(first: A, second: A): Boolean
|
||||
|
||||
@native class B(value: Int)
|
||||
external class B(value: Int)
|
||||
|
||||
fun box(): String {
|
||||
val a = A(23)
|
||||
|
||||
@@ -6,7 +6,7 @@ inline fun <reified T : Any> log(x: T) {
|
||||
global += T::class.js.name + ": " + x
|
||||
}
|
||||
|
||||
@native class C {
|
||||
external class C {
|
||||
override fun toString() = definedExternally
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@native interface I {
|
||||
external interface I {
|
||||
fun foo(): String
|
||||
}
|
||||
fun createObject(): Any? = null
|
||||
|
||||
Reference in New Issue
Block a user