Super interesting that Rust/C++/Swift have all converged on similar ideas for collections & identity but with different cost profiles.
eager copy of mutable values is still pretty creepy, and hard for me to understand. Impl detail: Are both sides CoW?
-
-
x = y logically creates two separate values always (x = y.clone()) -- impl-wise it's "first to mutate loses and clones"
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
The impl copies at least as much as is necessary to maintain the illusion of value semantics.
-
(we're not there in practice in all cases of course)
-
rubber meets the road on semantic diffs if you think accidental dealiasing is a worthwhile error to prevent.
-
If not for classes and trying to hide stored/computed property diff, one should be able to prevent that too.
-
? I mean like x = y x.mutate() // assume y changed Rust basically says "woah there pardner" by moving y
-
I see, *de*aliasing. Sorry
-
yeah I imagine telling an llvm dev "oh no my code isn't aliased enough" is like ERROR ERROR.

-
Yeah, we usually have the opposite problem of convincing FPers that value semantics mutation is OK
- 2 more replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.