Permalink
Fetching contributors…
Cannot retrieve contributors at this time
43 lines (33 sloc) 864 Bytes

RCS1099: Default label should be the last label in a switch section

Property Value
Id RCS1099
Category Readability
Default Severity Info
Enabled by Default
Supports Fade-Out -
Supports Fade-Out Analyzer -

Example

Code with Diagnostic

switch (s)
{
    default: // RCS1099
    case "a":
    case "b":
        break;
}

Code with Fix

switch (s)
{
    case "b":
    case "a":
    default:
        break;
}

See Also

(Generated with DotMarkdown)