https://kotlinlang.org logo
#multiplatform
Title
# multiplatform
b

Big Chungus

01/14/2020, 2:09 PM
Getting
Duplicate JVM class name
on MPP project with
common
and
JVM
sourceSets dectaring
expect/actual
fun some(a:Int, b:Any)
. Any suggestions?
d

Dominaezzz

01/14/2020, 2:10 PM
@JvmName
? Not sure if it'll work though.
Also, can you give more concrete example. (If the annotation doesn't work)
d

Dico

01/14/2020, 2:28 PM
I typically use
.common.kt
and
.jvm.kt
prefix or avoid definitions in common file. JvmName is also a good solution.
b

Big Chungus

01/14/2020, 5:07 PM
Turns out if you have top level expect fun and then some real code in the same file it becomes an error. But if it's just expects in the file, everyting works
d

Dico

01/14/2020, 10:29 PM
Yeah exactly, that's what I meant with definitions
187 Views