[Top][All Lists]

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

Re: show whitespace problems by default in diff-mode

From: Dan Nicolaescu
Subject: Re: show whitespace problems by default in diff-mode
Date: Thu, 16 Jul 2009 15:53:15 -0700 (PDT)

"Drew Adams" <address@hidden> writes:

  > > diff-mode is set up to show trailing whitespace problems, but it's not
  > > doing it by default, to enable this one has to do:
  > > 
  > > (add-hook 'diff-mode-hook 'whitespace-mode)
  > > 
  > > Vinicius also posted a patch to edit files to clean the trailing
  > > whitespace problems based on the diff.
  > > 
  > > Why not turn on whitespace-mode by default in diff-mode?  It makes
  > > spotting whitespace problems very easy, and will make it also easy to
  > > fix.
  > Perhaps for the same reason that whitespace diffs are ignored by default by
  > `diff' - because whitespace differences (including trailing whitespace) are
  > often _not_ so interesting.

Trailing whitespace is an annoyance most of the time, and it's not to be
conflated with the rest of the whitespace differences (which diff-mode
can ignore just fine -- C-c C-w).

  > I don't have a particular axe to grind, here. It's just not clear that most
  > people will want to show whitespace diffs (or even trailing whitespace) 
most of
  > the time. If you can support that claim, then sure, go for it.

I have yet to see anyone that wants to have trailing whitespace (which
are the only thing that might post is concerned with), but it's common
to see patches being rejected, or people asked to fix the patches
because of trailing whitespace problems.  Making it easy to spot and fix
such issues just helps our users.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]