emacs-devel
[Top][All Lists]
Advanced

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

where to put eol kludge


From: Thien-Thi Nguyen
Subject: where to put eol kludge
Date: Thu, 15 May 2003 19:05:58 -0400

(thinking out loud...)

the vms run-time `write' suffixes a gratuitous newline that for emacs 19
was worked around by adjusting point to be at a newline, and silently
suffering lack of workaround for gratuitous eof newline (see comment in
`Fwrite_region').  in trying to adapt this kludge to emacs 21, i gather
that the emacs 21 write path is now:

        Fwrite_region
        a_write
        e_write
        emacs_write
        sys_write
        write           (vms)

since emacs_write calls `encode_coding' (which eventually does eol
encoding handling selective-display as well), i wonder if that might be
a better place to move the kludge, than from the high level where it is
currently.  basically what is needed is to adjust the end of the buffer
that `write' sees so that it ends w/ newline.

of course, along the way we should write an autoconf test to detect the
necessity for such a kludge (i.e, just how broken `write' is) and then
omit it when not needed, but that's a side issue...

thi




reply via email to

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