Skip to main content
replaced http://stackoverflow.com/ with https://stackoverflow.com/
Source Link

It's not a correct edit.

It forces the editor's idea of preferred style on everyone else, when the existing style is not clearly problematic. Rather like the difference between 3 space indent and 4 space indent, or opening braces following the method signature vs on a new line.

There's nothing stylistically wrong with a very short method body being on a single line. It isn't even causing scrolling.

For example, in this questionthis question I really hate the following patterns:

struct Name {

and

} else

Both of those ought to have a newline, in my preferred style. But I'm not going to submit an edit doing so.

It's not a correct edit.

It forces the editor's idea of preferred style on everyone else, when the existing style is not clearly problematic. Rather like the difference between 3 space indent and 4 space indent, or opening braces following the method signature vs on a new line.

There's nothing stylistically wrong with a very short method body being on a single line. It isn't even causing scrolling.

For example, in this question I really hate the following patterns:

struct Name {

and

} else

Both of those ought to have a newline, in my preferred style. But I'm not going to submit an edit doing so.

It's not a correct edit.

It forces the editor's idea of preferred style on everyone else, when the existing style is not clearly problematic. Rather like the difference between 3 space indent and 4 space indent, or opening braces following the method signature vs on a new line.

There's nothing stylistically wrong with a very short method body being on a single line. It isn't even causing scrolling.

For example, in this question I really hate the following patterns:

struct Name {

and

} else

Both of those ought to have a newline, in my preferred style. But I'm not going to submit an edit doing so.

Source Link
Ben Voigt
  • 286.3k
  • 10
  • 112
  • 149

It's not a correct edit.

It forces the editor's idea of preferred style on everyone else, when the existing style is not clearly problematic. Rather like the difference between 3 space indent and 4 space indent, or opening braces following the method signature vs on a new line.

There's nothing stylistically wrong with a very short method body being on a single line. It isn't even causing scrolling.

For example, in this question I really hate the following patterns:

struct Name {

and

} else

Both of those ought to have a newline, in my preferred style. But I'm not going to submit an edit doing so.