www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 19469] New: File.byLine reuses buffer

https://issues.dlang.org/show_bug.cgi?id=19469

          Issue ID: 19469
           Summary: File.byLine reuses buffer
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: phobos
          Assignee: nobody puremagic.com
          Reporter: yshuiv7 gmail.com

For example:

stdin.byLine.array;

Will give you an array of the same string. Although this is the correct
behavior, it will surprise someone who is new to the language.

I think we should make byLine duplicate the string by default.

--
Dec 08 2018