lua-users home
lua-l archive

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


> more important, the fread may return > 0 but may have also set feof.
> If you call fread again and lf->f is a terminal it will wait for the
> next line or CTRL-D.

Thank you for this explanation.  Please add a comment to the code that
makes it easy for readers to understand this line of code.  You could
simply modify ET's quote if you're stuck for words.

/* EOF flag checked here because when lf->f is a terminal, the fread
   may return > 0 even when it is set.  If you call fread again and
   lf->f is a terminal it will wait for the next line or CTRL-D. */

John