This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: SVN pre-commit filter (Was: Re: WTF?)
On Fri, 2009-11-27 at 09:40 -0500, Joern Rennecke wrote:
> Quoting Richard Earnshaw <rearnsha@arm.com>:
> > An SVN pre-commit filter (default on, disabled by SVN attribute if
> > needed) should instead just reject files that have trailing white space.
>
> I think a better mechanism to deal with exceptions is to have a property
> that describes the current misformatting (or unusual formatting for some
> test cases / Makefiles). I.e. if a file is known to have N lines with
> trailing whitespace, M with spaces-for-tabs, K with
> spaces-hidden-in-front-of-tabs, and L with carriage return, a patch will
> be rejected if it increases N, M, K or L. If it decreases it, the count
> property can be auto-adjusted to prevent regressions. And if you really
> have to, you can adjust a property by hand before checking in a patch
> that increases one of the counts.
Sounds like unnecessary over-engineering to me. 99% of files should
have no trailing white space. The few that do probably have it for some
good reason and policing this by explicit count is most likely
pointless.
R.