Description
When assigning value of ternary result the condition is unexpectedly always moved to a new line. This looks especially weird if used with discard variable.
CSharpier 1.2.6
VS Extension 10.0.2
Steps to Reproduce
Take this code example:
class ClassName
{
void MethodName()
{
_ = true != null
? Foo.GetOneGetOneGetOneGetOneGetOneGetOne
: Foo.GetTwoGetTwoGetTwoGetTwoGetTwoGetTwo;
}
}
Expected Behavior
Expected is that code remains formatted as is. Assignment and condition check should be on the same line if line width allows it.
Actual Behavior
Condition is moved to a new line.
class ClassName
{
void MethodName()
{
_ =
true != null
? Foo.GetOneGetOneGetOneGetOneGetOneGetOne
: Foo.GetTwoGetTwoGetTwoGetTwoGetTwoGetTwo;
}
}
Description
When assigning value of ternary result the condition is unexpectedly always moved to a new line. This looks especially weird if used with discard variable.
CSharpier
1.2.6VS Extension
10.0.2Steps to Reproduce
Take this code example:
Expected Behavior
Expected is that code remains formatted as is. Assignment and condition check should be on the same line if line width allows it.
Actual Behavior
Condition is moved to a new line.