stdio performance in tango, stdlib, and perl

Deewiant deewiant.doesnotlike.spam at gmail.com
Thu Mar 22 04:41:42 PDT 2007


kris wrote:
> Deewiant wrote:
>> torhu wrote:
>>
>>> Unless a file is opened in binary mode, '\n' will be translated into
>>> '\r\n' on Windows.  And stdin, stdout, stderr is by default in ascii
>>> (not binary) mode.
>>
>>
>> But I don't think this is the case in Tango, so Cout(line)("\n")
>> should also be
>> changed for the benchmarks.
> 
> At the behest of andrei, Cin line-parsing now has an option to include
> the incoming line-terminator. That makes the "\n" somewhat redundant?

Only if you've got the latest SVN revision of Tango. If not, use
tango.io.FileConst.NewlineString (side note: for easier access, perhaps
Print.Eol should be public and assigned to this) in place of "\n".



More information about the Digitalmars-d mailing list