2 ms·
> No, that means 'reference', but the `mut` and lack of work mean exclusive mutability and const respectively. You keep saying this, but it's just not the most
by zozbot234 7y ago
> No, that means 'reference', but the `mut` and lack of work mean exclusive mutability and const respectively.
You keep saying this, but it's just not the most straightforward way of understanding the language - no matter what the official docs say at this time. It might be fair to complain about the lack of true 'const', 'pure' etc. specifiers in Rust, but to say that & references are 'const' references is just not sensible IMHO. It might make more sense to make a similar claim about C++, where the 'mutable' keyword really does seem to be a hack like you describe. But C++ has no borrow checker in the first place hence no such motive for 'interior' mutability - so it's in a totally different situation.