VariantArray methods take non mutable references
I noticed that methods such as set, resize, etc on VariantArray take non-mutable references, is this intentional?
Yes. There is a good article about what the reference types in Rust actually mean: Accurate mental model for Rust's reference types by dtolnay
Thanks for the article! So if I understand correctly the reason shared references make sense is because those methods on VariantArray (and other core types) are thread-safe.
Yes. According to the official guidelines these operations are considered thread-safe.
Closing because the question is answered.