AA ignores disabling of postblit for key types
Nordlöw via Digitalmars-d
digitalmars-d at puremagic.com
Fri Nov 4 08:21:20 PDT 2016
On Friday, 21 October 2016 at 18:35:38 UTC, Jonathan M Davis
wrote:
> On Friday, October 21, 2016 12:18:28 Nordlöw via Digitalmars-d
> wrote:
>> It seems AA's doesn't respect disabling of postblit for its
>> Key-type even when it's sent as an r-value.
>>
>> This is a serious bug.
>
> Well, I wouldn't expect it to work to use a non-copyable type
> as a key, but that should just result in a compilation error,
> not the mess that you're seeing. It wouldn't surprise me at all
> if the problem relates to the fact that the AA implementation
> uses void* internally (at least, from what I recall, that's
> what it does, which historically has meant a number of fun
> type-related bugs).
>
> - Jonathan M Davis
AFACT, it *should* be able to work with non-copyable types if
argument is an r-value. If somebody points out where to start
digging for this DMD I can give it at try.
1. issue a error when index is an l-value of noncopyable type
2. move the index if it's an r-value
More information about the Digitalmars-d
mailing list