Permalink
Fetching contributors…
Cannot retrieve contributors at this time
53 lines (43 sloc) 1.06 KB

Sort case labels

Property Value
Id RR0207
Title Sort case labels
Syntax selected case labels with string literal or enum field
Enabled by Default

Usage

Before

bool Foo(string s)
{
    switch (s)
    {
        case "d":
        case "b":
        case "a":
        case "c":
            return true;
        default:
            return false;
    }
}

After

bool Foo(string s)
{
    switch (s)
    {
        case "a":
        case "b":
        case "c":
        case "d":
            return true;
        default:
            return false;
    }
}

See Also

(Generated with DotMarkdown)