2 ms·
You don't need an HTTP boundary to make your own copy of data.
by treis 4y ago
You don't need an HTTP boundary to make your own copy of data.
- deleted 4y ago[deleted]
- BulgarianIdiot 4y agoDo you religiously deep-clone every container you pass to a function? No. So it's one thing to say you can copy your data, another to know your data is guaranteed to be copied. Swift has value types which use pass-by-value semantics. Containers use copy-on-write. This is a language where you can quickly build value trees that you know are a guaranteed copy, isolated from whoever sent you this tree. But most languages have no such infrastructure. Java is adding record types, but they're immutable instead of in-place mutable, which is incredibly inconvenient to work with in nested data structures.