LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   Warning: no newline at end of file (https://www.linuxquestions.org/questions/programming-9/warning-no-newline-at-end-of-file-16122/)

acid_kewpie 03-12-2002 04:21 PM

Warning: no newline at end of file
 
ok, i'm bored with staring at my terminals... one factor involved in the staring prompts me to ask...

Why on earth should I care if my source code file doesn't end in a new line?????

Mik 03-13-2002 02:53 AM

Because parsers that aren't written very well always expect a newline at the end of every line. They only check for a eof after they read the complete line including the newline. It's a lot simpler to write a parser that way. But most programs check for either newline or eof.


All times are GMT -5. The time now is 01:02 PM.