News for hackers. Stuff that matters.
Re:Is Uncle Bob serious? by zoul on Tuesday October 10, 2017 @09:15AM (#15441472)
Optional types are a good example of how types make a system safer. Sure, they are a pretty low-level guarantee, but that still counts—�and if you have an expressive type system, you can make much higher-level guarantees with types.
Re:Is Uncle Bob serious? by blub on Tuesday October 10, 2017 @09:24AM (#15441523)
I think they're great! I am pushing to use them in our C++ code base and they empirically do improve safety by transforming UB into a nice exception.

But they won't prevent a programmer from using MD5 for RSA signature verification.

Re:Is Uncle Bob serious? by dkersten on Tuesday October 10, 2017 @09:43AM (#15441668)
But if all of these things are correctly typed, then it would be visually more likely for someone to notice that the algorithm doesn't return the type it says.

Also, C++ static types are rather weak. Its optional types are useful, but its not like in SML where the compiler ensures that you handled all possible cases.

A good type system can't catch all kinds of errors though.