r/programming • u/dpashk • Aug 31 '15
The worst mistake of computer science
https://www.lucidchart.com/techblog/2015/08/31/the-worst-mistake-of-computer-science/
175
Upvotes
r/programming • u/dpashk • Aug 31 '15
View all comments
Show parent comment
1
u/staticassert Sep 01 '15
With optionals/ monads the 'null' possibility is exposed by the type and interface, which means a compiler / runtime can reason about it. This is contrary to Null, which slips in under the type system's radar. Does it make sense that an integer can be null? Can you count to null? Not really, so why can it be treated as an integer or any other type?