Re: [PATCH 3/3] git-apply: add tests for stripping of leading and trailing whitespace
From: Krzysztof Halasa <khc@pm.waw.pl>
Date: 2016-06-15 22:43:35
"J. Bruce Fields" [off-list ref] writes:
+test_expect_success \ + '8 or more consecutive initial spaces' \ + 'checkstrip 4'
It may be valid, some projects use tabs for indentation and spaces
for alignment, e.g.:
if (cond && (cond1 ||
cond2))
...
The second line is actually:
cond2))
<TAB--->SSSSSSSSSSSSScond2))
where 'S' means space.
This is the only way to write code which display correctly with
different tab sizes.
With tab = 4 spaces it would be expanded to:
if (cond && (cond1 ||
cond2))
...
I.e., it would be still fine.
Most of the formating tools probably can't do it automatically.
--
Krzysztof Halasa