Null safety is the Kotlin feature that most justifies leaving Java. Every type states whether it may hold null, the compiler refuses to let you use a possibly missing value as if it were there, and a few short operators make the missing case easy to handle. TypeScript's strictNullChecks works the same way until run time.
MENU
Null Safety
Null Safety and the Type System