Code Contracts
suggest changeVersions
Code Contracts apply to .NET Framework 4.0 through 4.6.2. The contract classes ship in the Framework; the rewriter and static checker are a separate Visual Studio extension.
Remarks
Code contracts allow compile-time or runtime analysis of preconditions and postconditions of methods, and of invariant conditions for objects. These conditions may be used to ensure callers and return values match valid states for application processing. Other uses for Code Contracts include documentation generation.
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents