News for hackers. Stuff that matters.
Re:Rust 0.2 released by kibwen on Friday March 30, 2012 @08:40AM (#3775639)
"apples and oranges are both represented as signed 32 bit integers, the allowable range for apples is 0..5, and you can't mix them"

While I can't say that I completely understand the underlying concepts, I believe that this is the sort of thing that Rust's typestate mechanism is intended to achieve (the way I seem to understand it, it's sort of like design-by-contract, except invariants may be checked at dozens of places per line rather than just at function boundaries). You should look into it if Ada's safety guarantees excite you.

There are no comments on this comment yet.