[Misc] Add test on typealiased SAM
This commit is contained in:
committed by
Dmitry Savvinov
parent
c1144f35f1
commit
8d1b063d62
+7
@@ -0,0 +1,7 @@
|
|||||||
|
package foo
|
||||||
|
|
||||||
|
expect interface Runnble {
|
||||||
|
public abstract fun run(): kotlin.Unit
|
||||||
|
}
|
||||||
|
|
||||||
|
public expect inline fun Runnble(crossinline block: () -> kotlin.Unit): Runnble
|
||||||
+9
@@ -0,0 +1,9 @@
|
|||||||
|
package foo
|
||||||
|
actual typealias Runnble = java.lang.Runnable
|
||||||
|
|
||||||
|
@Suppress("FunctionName")
|
||||||
|
public actual inline fun Runnble(crossinline block: () -> kotlin.Unit): Runnble = object : Runnble {
|
||||||
|
override fun run() {
|
||||||
|
block()
|
||||||
|
}
|
||||||
|
}
|
||||||
Generated
+5
@@ -169,6 +169,11 @@ public class MultiPlatformHighlightingTestGenerated extends AbstractMultiPlatfor
|
|||||||
runTest("idea/testData/multiModuleHighlighting/multiplatform/typeAliasedParameter/");
|
runTest("idea/testData/multiModuleHighlighting/multiplatform/typeAliasedParameter/");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("typeAliasedSam")
|
||||||
|
public void testTypeAliasedSam() throws Exception {
|
||||||
|
runTest("idea/testData/multiModuleHighlighting/multiplatform/typeAliasedSam/");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("useAppendable")
|
@TestMetadata("useAppendable")
|
||||||
public void testUseAppendable() throws Exception {
|
public void testUseAppendable() throws Exception {
|
||||||
runTest("idea/testData/multiModuleHighlighting/multiplatform/useAppendable/");
|
runTest("idea/testData/multiModuleHighlighting/multiplatform/useAppendable/");
|
||||||
|
|||||||
Reference in New Issue
Block a user