TypeName | ConstantsMustAppearBeforeFields |
CheckId | SA1203 |
Category | Ordering Rules |
Cause
A const field is placed beneath a non-const field.
Rule Description
A violation of this rule occurs when a const field is placed beneath a non-const field. Constants must be placed above fields to indicate that the two are fundamentally different types of elements with different considerations for the compiler, different naming requirements, etc.
How to Fix Violations
To fix an instance of this violation, place all consts above all fields.