On 05-Sep-2015 05:36, bitwise wrote:
On Friday, 4 September 2015 at 23:15:54 UTC, Andrei Alexandrescu wrote:
[...]
My thinking is that significant work in this(this) is poor D style.
Eager copying for containers doesn't seem like the best way to go. --
Andrei

I feel should add that I still very much favor simple value type
containers.

C++ does just fine with value-type containers. I know "D isn't C++" but
if it works, it works.

I agree if only on the grounds of composability. Value-typed containers are "more" then ref-based ones. As we can always get:

Unqiue!ValueTypedContainer or RC!ValueTypedContainer

on top of value type container.

I think the D community often tries way too hard
to be innovative, and in many cases, less is more. WYSIWYG is a much
more important principal to me than whatever resulted in a RefCounted(T)
that likes to dress up like a value type. Structs doing heavy work in
this(this) may be bad D style, but structs that don't act like structs
is worse.



--
Dmitry Olshansky

Reply via email to