[Issue 4287] opOpAssign!("~=") for std.array.Appender

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu Feb 7 18:14:59 PST 2013


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



--- Comment #10 from bearophile_hugs at eml.cc 2013-02-07 18:14:58 PST ---
(In reply to comment #9)

> I seemd to have skipped this part of the request. But you can open a new
> request for this.

OK. The length attribute is useful, to know at what point of the appending you
are...

But is adding opIndex() a good idea? It makes an appender a bit more similar to
an array. For some implementations Appender.opIndex() is O(ln x) instead of
O(1).

(And in the end what's the point of keeping both Appender and std.array.Array?
Isn't a well implemented Array (with a .data attribute) enough?).

Despite I think Appender.length is useful and I like it, at the moment I don't
have a clear use case for it in my D2 code. So unless I or other people will
need it, I think I will not open another ER for now. Thank you.

-- 
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