Re:Impressions of Rust as a Swift Developer: Memory Management
by monocularvision on Wednesday March 11, 2020 @10:35AM
(#22546168)
The author is wrong in their description. Some value types in Swift (like the standard library collection types like Array<T>) are value types with copy-on-write behavior. Until modified, copies of the Array are not made.
That copy-on-write functionality must be purposely implemented in the type and is not something provided automatically in Swift.
That copy-on-write functionality must be purposely implemented in the type and is not something provided automatically in Swift.