This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: error: "no newline at end of file"


* Manuel López-Ibáñez:

> C++ preprocessor emits errors by default for nonconformant code,
> following the C++ frot-end default behaviour.

Neither the C standard nor the C++ standard imposes any requirements
on concrete source code representation, so it's not quite right to
blame this issue on nonconformant code.

Unless there are other compilers which require a LF character at the
end of a file by default (and following this rule would increase
portability as a result), I don't think it's a good idea to impose
such a backwards incompatibility on users.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]