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

galex

03/18/2019, 10:17 AM
Hello, in an MP project for the iOS target we do not need to depend on a kotlin stdlib like we do for all the other sourcesets, what’s the reason for this?
r

ribesg

03/18/2019, 10:44 AM
There’s no specific native stdlib (yet?). The iOS sourceSet depends on the common sourceSet, which should depend on
stdlib-common
which contains all the mpp stdlibs.
stdlib-common
contains the pure Kotlin stdlibs,
stdlib
depends on
stdlib-common
and contains the JVM wrappers/extensions/etc for JVM stdlibs
r

r4zzz4k

03/18/2019, 10:47 AM
Native stdlib exists and we're using it in native targets, it's just added as a dependency implicitly and unconditionally.
r

ribesg

03/18/2019, 10:56 AM
Oh, ok. It’s added by the mpp plugin itself?
s

svyatoslav.scherbina

03/18/2019, 10:57 AM
Native stdlib is added by the compiler itself.
👍 4
g

galex

03/18/2019, 11:11 AM
Thank you for the explanation!
3 Views