> -----Original Message----- > From: Yasuo Ohgaki [mailto:yohgaki@;ohgaki.net] > Sent: 24 October 2002 07:42 > To: [EMAIL PROTECTED]; Alan Knowles > > Alan Knowles wrote: > > Im +1 for reverting the patch - (for what it's worth) > > > > This makes 2+ for having auto flushing :)
Add one more -- or even more, as I 'd say I'm +>1 for this! > BTW, real language (i.e. not shell) don't flush. Please let me > know if there is real language that do automatic flushing by > default. But PHP-CLI *is* a shell-scripting language, and therefore should behave like one. Other flavours of PHP aren't, and shouldn't. QED. > In addition, is it too difficult to write this kind of code? > > function prompt($prefix) { > echo $prefix; > flush(); > } > > I think this kind of code will be taught at the first > class of programming course. (I could be wrong, > since I don't know where people learned programming ;) At university: learned half-a-dozen languages; *all* of them flushed streams open on TTY either after every character, or (at line-end or when input requested from same device). I've been programming now for over 25 years, and this is *still* the behaviour I expect by default when programming command-line-executable scripts or programs. > Let's guess something interesting. > > How much % of scripts actually needs automatic flushing? > My guess is less than 1%. What is yours? For PHP-CLI: more than 90%. For PHP CGI or SAPI: much less than 1%. -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, visit: http://www.php.net/unsub.php