Is there a benefit to immutable data structures like in Clojure and erlang? What does it do for you versus just not mutating mutable objects?
Name:
Anonymous2011-12-29 20:30
They share structure. If you have a huge structure and you need a new version of it with just one changed value, without a structure-sharing data structure you'd need to copy the whole thing. Imagine your structure being 1MB and needing to be updated 1000 times a second, and you'll get it.