Immutability

There has been quite a few discussions on immutability lately. Patrick has written an excellent blog post summarizing some of the various thoughts on immutability along with a cool feature in NDepend to do immutable queries. The only thing that I would add is that immutability is definitely something to consider early on in the design process. It's much easier to start with a design that promotes immutability, rather then to try to graft immutability into an inherently imperative design.

Next time I will post on a specific bug that we had in the VB compiler that would have been prevented if the VB compiler implementation was designed to be more immutable then it is today.

Technorati Tags: Programming, Immutability

Comments