On 07/07/2016 03:51 AM, Guillaume Chatelet via Digitalmars-d wrote:
On Thursday, 7 July 2016 at 07:56:44 UTC, Stefan Koch wrote:
On Thursday, 7 July 2016 at 06:39:19 UTC, Guillaume Chatelet wrote:
On Tuesday, 5 July 2016 at 19:41:18 UTC, Guillaume Chatelet wrote:
DMD currently provides the Array type:
https://github.com/dlang/dmd/blob/master/src/root/array.d
[...]
Walter, Daniel, Thoughts?
I guess a few number of the perf difference this can make would be
helpful.
It's not so much about performance gain (although it wouldn't hurt).
It's more about codebase sanity: idiomatic D, documentation, tests. I
think it's currently hard to contribute to DMD. Sure it improved a lot
with the migration to D but it still bears the marks of the past.
If it's just for code sanity, why wouldn't an alias suffice? I often
alias types to create a "type" for a specialized purpose. Of course, if
you want a real type you could wrap it in a struct...which I do with
classes when it's *IMPORTANT* that the finalizer be called.