News for hackers. Stuff that matters.
Re:Retrofitting null-safety onto Java at Meta by Larrikin on Tuesday November 22, 2022 @02:07PM (#33709751)
That is wrong all, non annotated Java code gets a special type denoted with a ! . You can use ?. or assign it to a new val with ?: return.

Or you throw all the null safety away and write unsafe java code but in Kotlin the same as the Java code you're working with.

Re:Retrofitting null-safety onto Java at Meta by sedro on Tuesday November 22, 2022 @02:47PM (#33710389)
You can use ?. or assign to a nullable type. Or you can get a NPE at runtime. Which is to say, it's not null-safe.
Re:Retrofitting null-safety onto Java at Meta by Larrikin on Tuesday November 22, 2022 @02:56PM (#33710539)
So you're in the exact same case as you were in Java, which was my third point. But the type is a special type to let you know what you're doing is unsafe.