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]

Re: no newline at end of file



> What is the rationale for this warning ? What can break or is it a
> standards thing ?

Imagine foo.h:

blah blah blah<no newline>

Now bar.c:

#include "foo.h"
#include "grill.h"

Now imagine a preprocessor that isn't smart enough to put
the newline in for you...

blah blah blah#include "grill.h"

It may not include grill.h.


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