News for hackers. Stuff that matters.
Re:Why don't more languages offer flow typing? by LordDragonfang on Monday April 04, 2022 @04:13PM (#30911448)
>For example calling isNullOrBlank() on a nullable string changes to the type to nullable if the answer is false

For anyone confused like I was, that's a typo, it changes the type to not nullable. Likewise, isNullOrBlank() is an extension of the listed isNullOrEmpty().

https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.text/is-...

https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.text/is-...

There are no comments on this comment yet.