When writing in functional style in C #, are there any tools for statically checking that classes are immutable and functions are clean? I assume that this is not possible in the general case, but a tool that will be useful in 90% of cases will be useful.
I can imagine some reflection that checks that all member variables readonly, and that all member types (and all visible subtypes) are also immutable (recursively). I have no idea how the function check will start functioning.
source
share