
16 Jan
2009
16 Jan
'09
10:27 a.m.
On Fri, 16 Jan 2009, John Van Enk wrote:
2009/1/16 Peter Verswyvelen
[...]
After a while you decide that you need to change the Bla data type, maybe give Dog more fields, maybe completely redesign it, maybe not exposing it, but you want to keep existing code backwards compatible. With F# you can write Active Patterns for the old Dog and Cat constructors, so all existing code remains compatible. At least that is the way I understand it, but I have not actually worked yet with Active Patterns, will do so soon :)
You get something similar with the record syntax (though, probably still not quite as powerful as the active patterns):
... or use data-accessor package.