elect
04/13/2023, 8:52 AMoperator
methods involving inline classes?elect
04/13/2023, 8:52 AMPlatform declaration clash: The following declarations have the same JVM signature (plus-__B-jf8(JI)J):
inline fun Ptr<Byte>.`plus-__B-jf8`(offset: Int): Ptr<Byte> defined in kool
inline fun Ptr<Double>.`plus-__B-jf8`(offset: Int): Ptr<Double> defined in kool
inline fun Ptr<Float>.`plus-__B-jf8`(offset: Int): Ptr<Float> defined in kool
inline fun Ptr<Int>.`plus-__B-jf8`(offset: Int): Ptr<Int> defined in kool
inline fun Ptr<Long>.`plus-__B-jf8`(offset: Int): Ptr<Long> defined in kool
inline fun Ptr<Short>.`plus-__B-jf8`(offset: Int): Ptr<Short> defined in kool
Adam S
04/13/2023, 8:54 AM@JvmName
?
https://kotlinlang.org/docs/java-to-kotlin-interop.html#handling-signature-clashes-with-jvmname
https://kotlinlang.org/docs/inline-classes.html#calling-from-java-code
You can call functions that accept inline classes from Java code. To do so, you should manually disable mangling: add theannotation before the function declaration@JvmName
elect
04/13/2023, 8:56 AMJvmName
couldn't work with operators
..elect
04/13/2023, 8:58 AMAdam S
04/13/2023, 8:58 AM