Can the resolver automatically format case statements on a single line?

I am trying to find a way to reformat single-line formatting statements, as shown:

switch (number)
{
    case 0: return 50;
    case 1: return 51;
    default: return 0;
}

It is currently formatted as follows:

switch (number)
{
    case 0: 
        return 50;
    case 1: 
        return 51;
    default: 
        return 0;
}
+4
source share
1 answer

As of R # 9.1, this is not supported. However, there is an element in the ReSharper tracker that you can follow and / or vote if you want this to be enabled. Currently, it has a "critical" priority, which indicates what is considered to be included.

https://youtrack.jetbrains.com/issue/RSRP-388810

0
source

Source: https://habr.com/ru/post/1526257/


All Articles