Support suspend functions as superinterfaces
Forbid mixing suspend and non-suspend functional supertypes. Since JVM BE generates suspend functional types as non-suspend ones with SuspendFunction marker interface, there is not way to distinguish non-suspend functional type from suspend one if they are mixed. #KT-18707 Fixed
This commit is contained in:
js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/es6/semantics/IrJsCodegenBoxES6TestGenerated.java
Generated
+5
@@ -6558,6 +6558,11 @@ public class IrJsCodegenBoxES6TestGenerated extends AbstractIrJsCodegenBoxES6Tes
|
||||
runTest("compiler/testData/codegen/box/coroutines/suspendFunImportedFromObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("suspendFunctionAsSupertype.kt")
|
||||
public void testSuspendFunctionAsSupertype() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/coroutines/suspendFunctionAsSupertype.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("suspendFunctionMethodReference.kt")
|
||||
public void testSuspendFunctionMethodReference() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/coroutines/suspendFunctionMethodReference.kt");
|
||||
|
||||
Generated
+5
@@ -5969,6 +5969,11 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
|
||||
runTest("compiler/testData/codegen/box/coroutines/suspendFunImportedFromObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("suspendFunctionAsSupertype.kt")
|
||||
public void testSuspendFunctionAsSupertype() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/coroutines/suspendFunctionAsSupertype.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("suspendFunctionMethodReference.kt")
|
||||
public void testSuspendFunctionMethodReference() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/coroutines/suspendFunctionMethodReference.kt");
|
||||
|
||||
Generated
+5
@@ -5969,6 +5969,11 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
|
||||
runTest("compiler/testData/codegen/box/coroutines/suspendFunImportedFromObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("suspendFunctionAsSupertype.kt")
|
||||
public void testSuspendFunctionAsSupertype() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/coroutines/suspendFunctionAsSupertype.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("suspendFunctionMethodReference.kt")
|
||||
public void testSuspendFunctionMethodReference() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/coroutines/suspendFunctionMethodReference.kt");
|
||||
|
||||
Reference in New Issue
Block a user