www.digitalmars.com         C & C++   DMDScript  

D - [bug] error if eof not eol

reply Lewis <dethbomb hotmail.com> writes:
Not sure if this was already brought up or not, (or if your already aware of
it) 
but seems like alot of text line unput programs have this bug in that if the 
last line in your source program doesnt end in \r\n (or \n) then it errors 
depending on what you have there.

for example i have this as the last line in one of my D files

} // End of  Extern(Windows)

but theres no \n after it so it errors, the work around is of course to add a 
blank line at the end of your file.  not a big issue to me but thought i would 
mention it.

regards
lewis miller
Dec 23 2003
parent davepermen <davepermen_member pathlink.com> writes:
same for comments... //stuff

In article <bs8vrt$8nb$1 digitaldaemon.com>, Lewis says...
Not sure if this was already brought up or not, (or if your already aware of
it) 
but seems like alot of text line unput programs have this bug in that if the 
last line in your source program doesnt end in \r\n (or \n) then it errors 
depending on what you have there.

for example i have this as the last line in one of my D files

} // End of  Extern(Windows)

but theres no \n after it so it errors, the work around is of course to add a 
blank line at the end of your file.  not a big issue to me but thought i would 
mention it.

regards
lewis miller
Dec 23 2003