Trying to make sense of Rust's type system