[Issue 11138] New: "real" appender missing

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Sep 29 03:23:31 PDT 2013


http://d.puremagic.com/issues/show_bug.cgi?id=11138

           Summary: "real" appender missing
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Phobos
        AssignedTo: nobody at puremagic.com
        ReportedBy: verylonglogin.reg at gmail.com


--- Comment #0 from Denis Shelomovskij <verylonglogin.reg at gmail.com> 2013-09-29 14:23:28 MSD ---
Lets call "real" an appender which will create the one and only array, i.e. it
will not randomly create a copy of array on appending. Such copy is bad as:
1. Almost no use.
    In 99% appender is used as "real" appender and the copy is not needed.
2. Performance.
    It will cause calls of postblits and then destructors on collection of copy
array.
3. Needless restriction on element type.
    One may want to create and array of uncopyable type which non-"real"
appender can't do by definition.

Obviously, "real" appender is uncopyable and don't give safe access to its
array until it finished.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list