Maintainability Warnings

Note

This article applies to Visual Studio 2015. If you're looking for the latest Visual Studio documentation, see Visual Studio documentation. We recommend upgrading to the latest version of Visual Studio. Download it here

Maintainability warnings support library and application maintenance.

In This Section

Rule Description
CA1500: Variable names should not match field names An instance method declares a parameter or a local variable whose name matches an instance field of the declaring type, which leads to errors.
CA1501: Avoid excessive inheritance A type is more than four levels deep in its inheritance hierarchy. Deeply nested type hierarchies can be difficult to follow, understand, and maintain.
CA1502: Avoid excessive complexity This rule measures the number of linearly independent paths through the method, which is determined by the number and complexity of conditional branches.
CA1504: Review misleading field names The name of an instance field starts with "s_", or the name of a static (Shared in Visual Basic) field starts with "m_".
CA1505: Avoid unmaintainable code A type or method has a low maintainability index value. A low maintainability index indicates that a type or method is probably difficult to maintain and would be a good candidate for redesign.
CA1506: Avoid excessive class coupling This rule measures class coupling by counting the number of unique type references that a type or method contains.

See Also

Measuring Complexity and Maintainability of Managed Code