bug-groff
[Top][All Lists]
Advanced

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

pic inconsistently diagnoses carriage returns


From: Doug McIlroy
Subject: pic inconsistently diagnoses carriage returns
Date: Wed, 08 Feb 2012 11:56:15 -0500
User-agent: Heirloom mailx 12.5 7/5/10

pic 1.21 is inconsistent about detecting carriage-return characters.
For example, if pic is given this file with CRLF line terminations
(as may happen when used in Windows), carriage returns are
diagnosed only on the last two lines.  Pic also reports "there is
no variable 'f'".  (The first .PS is not recognized because
it is delimited by \r.)

.PS
define f { $1 }
.PE
.PS 2i
a = f(0)
.PE

Things get really mysterious if the first .PS...PE is in a separate
file, with CRLF terminations, that is included via .PS <source
in a second file with LF terminations.  Then the only
diagnostic is "there is no variable 'f'".  (In fact this
scenario is what brought the problem to my attention.)




reply via email to

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