comp.lang.ada
 help / color / mirror / Atom feed
From: Simon Wright <simon@pushface.org>
Subject: Re: Ada.Text_IO.Get_Line issue in windows
Date: Wed, 03 Jun 2015 12:14:00 +0100
Date: 2015-06-03T12:14:00+01:00	[thread overview]
Message-ID: <lysia9vybr.fsf@pushface.org> (raw)
In-Reply-To: mkmjn9$ctj$1@dont-email.me

Simon Clubley <clubley@remove_me.eisner.decus.org-Earth.UFP> writes:

> On 2015-06-03, Simon Wright <simon@pushface.org> wrote:

>> It took me some time to realise that Emacs was automatically adding a
>> linefeed to the end of the example file.
>
> That behaviour is adjustable in Emacs and the default with early
> versions of Emacs was _not_ to add the line terminator to the final
> record in the file.
>
> I have had the following line in my .emacs since the 1990s:
>
> 	(setq require-final-newline t)
>
> However, your comment above implies that the default has changed so I
> don't know if that's now obsolete in the very latest Emacs versions.

Looks as though text-mode (& message-mode?) set it to t (my global
default is nil).

C-h v:

require-final-newline is a variable defined in `files.el'.
Its value is t
Original value was nil
Local in buffer *unsent followup to Simon Clubley on comp.lang.ada*; global value is nil

  This variable is safe as a file local variable if its value
  satisfies the predicate `symbolp'.

Documentation:
Whether to add a newline automatically at the end of the file.

A value of t means do this only when the file is about to be saved.
A value of `visit' means do this right after the file is visited.
A value of `visit-save' means do it at both of those times.
Any other non-nil value means ask user whether to add a newline, when saving.
A value of nil means don't add newlines.

Certain major modes set this locally to the value obtained
from `mode-require-final-newline'.

You can customize this variable.

  reply	other threads:[~2015-06-03 11:14 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-01  5:07 Ada.Text_IO.Get_Line issue in windows tornenvi
2015-06-02  2:44 ` AdaMagica
2015-06-03  5:54   ` tornenvi
2015-06-03  6:32     ` Jeffrey R. Carter
2015-06-05  4:10       ` tornenvi
2015-06-03  7:02 ` Simon Wright
2015-06-03 10:08   ` Simon Clubley
2015-06-03 11:14     ` Simon Wright [this message]
2015-06-08 22:47 ` wowwomenonwheels205
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox