Hi Pifta, I have the following arguments for relaxing the line length limit:
* The problem is asymmetric: given a longer line limit we can use short lines, but not the other way around. I would like to break lines where it makes sense to do so (as you say "wrapping that helps the understanding of what I am trying to express in the code"). * Same goes for tool support: * You can configure your editor to soft-wrap long lines to match your reading preference, but not to soft-join short ones. * Similarly, your editor may be able to hard-wrap to make it easier to adhere to the length limit, but I don't think it will auto-join lines when they get shorter. * Line length limit and self-explanatory (ie. reasonably long) names impose conflicting requirements. * Sometimes you cannot even change long names (generated or third-party code). * You may violate the line length limit even in files you never open. Refactoring and auto-wrap don't mix. * Adherence to limits may trigger more change than necessary, so reviewers have to look harder to find the meat of the change. (This is similar to reordering imports unnecessarily). * I would like to avoid spending time trying to satisfy such rules (eg. the situation you describe where you "try to separate things visually"). I agree that for any specific length limit there will be situations where that limit is not enough. But I think we can agree that the lower the limit the more frequently this is likely to happen. I think assuming good will and having peer review are better safe-guards for this than strict rules. > I have the following personal reasons: > - in my laptop, I can have two files in IDEA splitted horizontally with a > line length of 80, with 120 I loose this property of our source code > - in my big monitor, I can fit 4 different files in IDEA splitted > horizontally, or I can have my browser open beside my IDEA on the same > screen, with line length of 80, with 120 I loose this property or at least > I might need horizontal scrolling in the browser These depend on resolution and font size. You may be able to change them to satisfy your requirements. > - typography studies shows that the ideal line length for reading is around > 45-75 characters long, ... > https://baymard.com/blog/line-length-readability > https://www.smashingmagazine.com/2014/09/balancing-line-length-font-size-responsive-web-design/ I think these studies are about prose, not code. I don't think you read these two the same way. -Attila --------------------------------------------------------------------- To unsubscribe, e-mail: ozone-dev-unsubscr...@hadoop.apache.org For additional commands, e-mail: ozone-dev-h...@hadoop.apache.org