Braces Layout - Array and object initializer - BSD Style - wrong indent

I am having an issue that significantly reduces my efficiency and drives me crazy...

I need to have the following formatting:

int[] array = new int[]

{

    1, 2, 3

}

 

JetBrains ReSharper Ultimate 2018.1.4

6 comments
Comment actions Permalink

It turns out that the issue comes from StyleCop.

How can I disable braces indent override?

0
Comment actions Permalink

Can you confirm that when "Fix StyleCop violations" is disabled in your code cleanup profile, that this doesn't happen anymore?

0
Comment actions Permalink

Could you tell me how that can be done?

0
Comment actions Permalink

It's not exactly clear to me which formatting you intend to have. Should the braces be aligned with the variable declaration or with the array creation expression (as depicted in your screenshot).

 

The setting I'm talking about is this:

 

0
Comment actions Permalink

Hi Matthias,

It does not seem like I can change it. Should I duplicate the existing one and remove Fix StyleCop violations from it? Should I delete the old one after that? Which of the cleanup profiles should be selected by default? 

0

Please sign in to leave a comment.