On 06/19/2015 11:37 PM, Timon Gehr wrote:
On 06/19/2015 05:27 PM, Andrei Alexandrescu wrote:
On 6/19/15 8:01 AM, "Ulrich =?UTF-8?B?S8O8dHRsZXIi?=
<[email protected]>" wrote:
If opAssign is allowed, a major point of functional data structures is
lost. Client code is so much better if rebinding is off the table.
I have the same instinct but not enough rationale. What would be an
example in favor of the argument?
I think he is just arguing for immutable by default. The obvious
counter-argument is: Show me the implementation of the
'length(T)(SList!T)' function for SList!T with disabled opAssign.
Bad example, you'd just use the range, I guess. :o)
Append?