2 ms·
Interesting, I haven't heard this argument before. So what is it about null that makes it more feasible here than for example option types/tagged unions? Also,
by htgb 8y ago
Interesting, I haven't heard this argument before. So what is it about null that makes it more feasible here than for example option types/tagged unions?
Also, regarding your third point, IMO the question mark syntax in for example TypeScript and C# is fine.
- annabellish 8y agoWay back when when the JVM/CLR were being originally designed, I'm not sure that Option types as a concept were quite as proven, and both languages were trying to be "safe" languages that didn't have any complicated or new concepts in them. Optional types might not be that now, but they probably were then, when they were strictly in the domain of fairly academic languages.
- ratmice 8y agoI'm not entirely sure where or when it was introduced, the first mention of it I could find was May 1989 (pg 25) ftp://ftp.cs.princeton.edu/reports/1989/220.pdf