David Nadlinger:

http://www.reddit.com/r/programming/comments/u84fc/purity_in_d/

On Reddit "yogthos" has said:
http://www.reddit.com/r/programming/comments/u84fc/purity_in_d/c4t8czg

they're called persistent data structures, and wikipedia has a nice article showing how they work. These are implemented in languages like Haskell and Clojure, and offer performance that's within that of using mutable data.<

Those data structures are interesting, they are persistent so they remove certain classes of bugs and allow for certain high-level algorithms, they play well with multiple CPUs cores, so probably they will be handy in D too. But on a single CPU their performance is not so good compared to mutable flat array-based data structures. Idiomatic Clojure code is often slow, and it uses tons of RAM, several times the memory used by equivalent Python code. So the situation isn't as good as they keep saying.

Bye,
bearophile

Reply via email to