Great article by <@U0B8SM5FX>, A Kotlin Schrödinge...
# feed
m
Great article by @alexfacciorusso, A Kotlin Schrödinger Cat, it now on Kotlin Academy 😄 https://blog.kotlin-academy.com/a-kotlin-schr%C3%B6dinger-cat-c0aeee5e7443
👍 2
b
in Kotlin, every child object of a nullable object will inherit that nullability.
can someone direct me to the relevant documentation on this behavior?
j
bob?.department?.head?.name
is of type
String?
and is null if any of bob, department or head is null http://kotlinlang.org/docs/reference/null-safety.html#safe-calls
b
that i understand, but that is not what i had inferred "every child object of a nullable object" to be in reference to -- it had sounded to me like the author was making an assertion about fields/properties.