On 9/24/11 6:30 AM, Trass3r wrote:
This means that objects with large state would need to use things like
COW and/or reference counting.
Isn't an expensive-to-copy type supposed to be a class anyway?
Well not always - see BigInt.
I'd go as far as requiring this(this) to be nothrow, but perhaps it
would be best to see whether that is a necessity.
Don't memory allocations prevent a function from being nothrow?
A nothrow function may allocate memory, but allocating inside this(this)
would be a faux pas.
Then this would make it impossible to properly wrap an array in a struct.
COW would help there.
Andrei