4 ms·
Doesn't Rusts linear type system ensure the latter?
by Certhas 12y ago
Doesn't Rusts linear type system ensure the latter?
- chongli 12y agoBut is Rust a popular language? Weasel words strike again!
- arielb1 12y agoFunctional languages, along with Rust's linear type-system, can ensure this for single-ownership structures (trees, singly-linked lists), but not for structures with more complex ownership, like doubly-linked lists. The unpopular languages I was talking about were Agda and friends.
- pcwalton 12y agoTo be clear, though, Rust's type system can ensure thread safety of doubly-linked lists if you use the doubly-linked list structure in the standard library (or write one yourself using RC/etc.)
- steveklabnik 12y agoWe technically have affine types, not linear.