FxCop rules for functional programming

Languages like C# 3 have come on great leaps and bounds when it comes to allowing a functional programming constructs. However, they are at heart imperative languages. I wonder whether you could use FxCop/Code Analysis rules to try to bully yourself into correct behaviours, like using immutable variables.

I have no idea how to go about doing this — particularly, I don’t really understand what the rules should be — but I think it would be interesting to develop a C# project with a set of rules promoting a functional style; it might be easier than, say, learning [F#](http://msdn.microsoft.com/en-us/fsharp/default.aspx?ppud=4).

Advertisements