Skip to content

Latest commit

 

History

History
46 lines (36 loc) · 677 Bytes

RCS1003.md

File metadata and controls

46 lines (36 loc) · 677 Bytes

RCS1003: Add braces to if-else (when expression spans over multiple lines)

Property Value
Id RCS1003
Category Style
Severity Info

Example

Code with Diagnostic

if (condition) // RCS1003
    WhenTrue(
        x,
        y);
else
    WhenFalse(
        x,
        y);

Code with Fix

if (condition)
{
    WhenTrue(
        x,
        y);
}
else
{
    WhenFalse(
        x,
        y);
}

See Also

(Generated with DotMarkdown)