QUESTION TYPE THEORY RUST
OK so I keep seeing people online — including in some CS courses and blog posts — describe Rust's ownership model as basically "linear types from type theory." You know the pitch: Girard invented linear logic in 1987, linear logic gives you "use exactly once" semantics, Rust enforces single ownership, therefore Rust has linear types. QED, ship it.
But every time I dig into it, the picture gets murkier. Most types in Rust are what are called affine types — they can only be used one or zero times. To use them is to move them; not to use them is to drop them. That's what ownership means.
The crucial distinction being: linear types correspond to linear logic and ensure that objects are used exactly once. This allows the system to safely deallocate an object after its use, or to design software interfaces that guarantee a resource cannot be used once it has been closed or transitioned to a different state.
Rust values can be dropped without being used — that's "at most once," not "exactly once." So Rust is affine, not linear. But is calling it "basically linear types" a useful oversimplification, or is it actively misleading? Discuss.