Every time I let ReSharper format my code, it removes the blank line I put between the namespace and class declaration.
From this:
namespace Test {
public class Test {
To this:
namespace Test {
public class Test {
It does the same thing with the blank lines at the closing braces of both.
All my “blank line” settings are set to 1, except for single line fields.
Is there an option I’m missing?
Fsck, just 10 minutes ahead of me. Well, I’ll answer anyway. Bad news is that it’s a long-time feature request http://youtrack.jetbrains.com/issue/RSRP-74903
Good news is that it would fixed in the tomorrow’s 7.1 EAP build. There would be new options in
ReSharper | Options -> Code Editing | C# | Formatting style | Blank Lines:Remove blank lines after "{" and before "}" in declarations(turn it off to prevent ReSharper from removing blank line) andAround namespaceandAround type(set it to non-zero value to force ReSharper to add blank lines).