[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Is this correct behaviour for (princ ...)
- To: Bruno Haible <haible@ilog.fr>
- Subject: Re: Is this correct behaviour for (princ ...)
- From: William Edward Webber <wew@yallara.cs.rmit.edu.au>
- Date: Thu, 13 Nov 1997 01:25:53 +1100
- Cc: William Edward Webber <wew@yallara.cs.rmit.edu.au>, clisp-list@ma2s2.mathematik.uni-karlsruhe.de
- In-reply-to: Your message of "Wed, 12 Nov 1997 14:19:51 BST." <199711121319.OAA24705@halles.ilog.fr>
>> an extra blank line is inserted between each line using clisp (1997-09-22),
>> whereas if I use (write-char ...) instead of (princ ...) the file is copied
>> correctly.
>
>I don't understand how this is possible. `princ' on a character does a
>`write-char'; I just looked at the code. Are you on Win32 ? Does your
>file contain CR/LFs as line terminators or simple LFs? What does
>(mapc #'princ '(#\x #\cr #\newline #\y)) print on your screen? Do you
>have dribbling enabled?
Hi!
> (mapc #'princ '(#\x #\cr #\newline #\y))
x
y
(#\x #\Return #\Newline #\y)
> (mapc #'write-char '(#\x #\cr #\newline #\y))
x
y
(#\x #\Return #\Newline #\y)
>
both running in an xterm and as an inferior process under Emacs.
Also:
> (mapc #'princ '(#\x #\newline #\newline #\y))
x
y
(#\x #\Newline #\Newline #\y)
> (mapc #'princ '(#\x #\newline #\d #\newline #\y))
x
d
y
(#\x #\Newline #\d #\Newline #\y)
> (mapc #'write-char '(#\x #\newline #\d #\newline #\y))
x
d
y
(#\x #\Newline #\d #\Newline #\y)
>
etc.
To questions 1, 2, and 4: my OS is Linux, it was a standard Unix file (i.e.
LFs only), dribbling was not enabled.
Is this a peculiarity with the Linux ELF binary of 1997-09-22? Is there
any other debugging info I can give you?
Regards,
William Webber