-
-
Notifications
You must be signed in to change notification settings - Fork 105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixing indentation issues with conditionals inside initializers #534
Conversation
@@ -141,6 +141,27 @@ class ClassName | |||
new Thing { One = 1 }, | |||
Two = 2 | |||
}; | |||
|
|||
var conditionalsAndInvocations = new List<SomeObject> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Damn, this whole block looks really good ✨
this.CallSomeMethod________________________________________() | ||
.CallSomeMethod________________________________________(), | ||
someLongCondition___________________________________ | ||
&& someLongCondition___________________________________ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did we decide not to indent binary operators, again?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case if it were indented, then it would line up with the ?
Maybe #3 below is the way to go? I think there might be some cases where binary operators do get indented.
someLongCondition___________________________________
&& someLongCondition___________________________________
? one
: two
someLongCondition___________________________________
&& someLongCondition___________________________________
? one
: two
someLongCondition___________________________________
&& someLongCondition___________________________________
? one
: two
closes #529