emacs-devel
[Top][All Lists]
Advanced

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

Re: cc-mode adds newlines


From: Andreas Schwab
Subject: Re: cc-mode adds newlines
Date: Sun, 21 Nov 2004 16:18:08 +0100
User-agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (gnu/linux)

Andries Brouwer <address@hidden> writes:

> On Sun, Nov 21, 2004 at 02:51:49PM +0100, David Kastrup wrote:
>
>> "happens to work" and "valid" are two different things.  I don't know
>> any C standard that would specify well-defined behavior for a file
>> with a missing newline at the end.  The term "valid" is defined by a
>> language definition, not by the behavior of a particular
>> implementation.
>
> Let me quote the Reference Manual in front of me.
>
> "Blanks, tabs, newlines, and comments (collectively, "white space")
> are ignored except as they serve to separate tokens."

So you agree that adding a newline at the end of a valid C source file can
never produce an invalid C source file?

Andreas.

-- 
Andreas Schwab, SuSE Labs, address@hidden
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."




reply via email to

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