Re: Minor whitespace changes relating to lines of code that are being changed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Chris,

On 2025-02-13 11:36, Chris Sherlock wrote:
I see commits all the time where someone changes a line of code and changes the whitespacing in that same line of code.

So for example, in https://gerrit.libreoffice.org/c/core/+/178504 I have removed the using namespaces and added css:: as the prefix, but at the same time *only* on the lines of code that I touched I fixed up the inconsistent whitespacing.

Please double-check your "*only* on the lines of code that I touched I fixed up the inconsistent whitespacing" assumption, as the change contains various whitespace-only changes like

-    catch( const css::uno::Exception& )
+    catch(const css::uno::Exception&)

, see also comment [1] in the change.


Given the code compiles and it is very obviously what change is being made, what is the problem with doing this?

When changing *unrelated* lines, it makes it harder to see the "actual change", which makes some things more challenging, e.g.:

* understanding what a commit does at a quick glance
* reviewing the code
* identifying what exactly went wrong in a commit if it introduced a regression (a bibisect identified this commit)


[1] https://gerrit.libreoffice.org/c/core/+/178504/comments/e0412f51_6cafdaa6

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature


[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux