emacs-devel
[Top][All Lists]
Advanced

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

Re: EOL: unix/dos/mac


From: Stephen J. Turnbull
Subject: Re: EOL: unix/dos/mac
Date: Wed, 27 Mar 2013 01:16:36 +0900

Stefan Monnier writes:
 > > Unicode doesn't care, you know: it considers all ASCII line breaks and
 > > terminators to be the same thing (NEW LINE FUNCTION).
 > 
 > But when saving the file, which line ends would we use?
 > For pre-existing line-ends, we could reproduce what was there before,
 > but what about new lines?

Basically, what Eli said.  To remind you how flexible this is: The
file coding system including EOL convention would be determined as it
currently: a specific argument to write-file or the binding of
buffer-file-coding-system, in that order.  The last would be
determined as currently: user's explicit setting, various settings
based on alists, and finally heuristic autodetection based on file
contents and platform convention for new/empty files.

We'd need an additional control variable: whether to automatically
convert variant NLFs to the EOL convention for writing.  Or perhaps
this should be done on reading.  And a command to do it at the user's
convenience.





reply via email to

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