[Top][All Lists]

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

Re: [Groff] End-of-line whitespace.

From: Ralph Corderoy
Subject: Re: [Groff] End-of-line whitespace.
Date: Sun, 09 May 2010 17:26:54 +0100

Hi Ted,

> > I could match / *$ but it seems more logical to insist on an least
> > one space being present, as you do.
> Matching a single space would be fine if you were confident of at most
> one trailing space. NBut it's more than "logical", it is very
> practical in many cases, to allow for more than one.

No, I meant at least one space, not just one space.  / *$ matches on
every line, including those with no trailing spaces.  The spaces, if
there are any, would then be deleted.  To my mind, I'm making ed, vi, or
whatever, go to the effort of doing the "replace" part when I know it's
a waste of time so I "optimise" things by giving it the /  *$
one-or-more space regexp.  :-)

> Here it may well be simply a matter of taste.

Yes, quite true.  Another way...  in the past, I've had makefile rules
that check for EOL spaces, along with other things.


reply via email to

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