Update (2018-11-03)
This is a known issue that is being tracked here.
Original Post
I am playing around with Kotlin MPP, specifically with Kotlin 1.3 and the new structure. After converting a Kotlin 1.2 MPP to the new structure, I keep getting these errors:
Error:(3, 18) Kotlin: [MPP_jvmMain] Declaration annotated with '@OptionalExpectation' can only be used in common module sources
These are referring to the @JsName()
annotations I have within my common module.
I have tried:
@JsName("test")
to the hello()
function that comes with the generated sample. Even that seems to cause problems. ./gradlew build
from the command line. This works. This was fixed within v1.3.10 of the Kotlin plugin for IntelliJ.