Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> NULL/missing is so common that it makes sense to provide special language support, even if you don't have full unions. See e.g. Kotlin and Typescript.

No it doesn't. It's a bad idea in programming languages just as it's a bad idea in SQL.



Given that a lot of non-niche modern languages disagree with you and you provide no rationale, I remain unconvinced.

Swift, Kotlin, Javascript/Typescript along with some older languages (PHP, C#, probably more) have special null-handling in the language. Go and Rust do it differently, but do have an extremely strong opinion on how missing values should be handled.


There are tradeoffs - if you go against the zeitgeist and ban nulls then you risk people you need to please for success sticking their nose up at you. It is a bit like car safety features - if it is such a good idea why wasn't it taken seriously until say the 90s.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: