I am experimenting with the multiplatform feature ...
# multiplatform
d
I am experimenting with the multiplatform feature using version 1.2.21 and I am having a bit of a puzzled moment. This is in my common module:
Copy code
expect class ExtensionType<E : Any>
fun <E : Any> doSomething(type: ExtensionType<E>): String = "$type" // example!
In my JVM module I am now doing this:
Copy code
actual typealias ExtensionType<E> = Class<E>
I would now expect to be able to call
doSomething(SomeClass::class.java)
in the JVM module, since there
ExtensionType = Class
. However IntelliJ complains about a type mismatch between the two. Why is that? And how can I achieve something similar?