https://kotlinlang.org logo
#kotlin-native
Title
# kotlin-native
k

kevin.cianfarini

01/20/2023, 2:54 PM
Are value classes that are exposed to Swift expected to be erased to
Any
? I searched YouTrack and didn’t see anything.
Copy code
@JvmInline value class Url(val value: String) {
    init {
        require(value.isValidUrl()) {
            "$value is not valid URL."
        }
    }
}
Ah shit, I see it’s unsupported. https://kotlinlang.org/docs/native-objc-interop.html#mappings It didn’t appear in my initial search because this is using the legacy
inline class
terminology
2 Views