Conversation
* Increase line length. * Allow more freedom to manually break lines. * Don't inline if statements * Use only one tab for indentation in enum classes. (fix)
|
@maarzt Thanks for working on this. I like these changes for the most part. I'm sad to see the 80 limit go because the only true terminal size is 80x25 forever, but at the same time it's a huge pain in practice and having it longer is really better. So I accept it. I do not like the change to inlining of String lang = ss.getLanguageByName(arg);
if (lang == null) lang = ss.getLanguageByExtension(arg);
if (lang == null) lang = doSomeOtherFallback(arg);When the consequents are not inlined anymore, it becomes: String lang = ss.getLanguageByName(arg);
if (lang == null)
lang = ss.getLanguageByExtension(arg);
if (lang == null)
lang = doSomeOtherFallback(arg);Which I find to be ugly and a waste of space. It's even worse IMHO with the I'm probably willing to cave on this, since probably everyone else disagrees with me, but just wanted to throw in why the style was like this up till now. |
I would like to improve the scijava coding style in a similar manner as done with the imglib2 coding style.
The main change is that the code formatter now is less likely to remove manually placed new line characters.
This combined with a longer line length gives us programmers more freedom when using the coding style.
This demo PR shows the impact of the changes on the scijava-common repository.
Changes: