RefCounted: conflicting overloads of refCountedPayload()
bitwise via Digitalmars-d
digitalmars-d at puremagic.com
Sat Jan 28 13:24:11 PST 2017
On Saturday, 28 January 2017 at 20:14:29 UTC, bitwise wrote:
> I'm having trouble creating a minimal repro, but the error is:
Managed to get a repro working.
Commenting out the alias 'X' makes the error go away.
If someone can confirm my sanity, I'll file a bug for this.
---
struct S {
struct Payload {
int[] data;
}
RefCounted!(Payload, RefCountedAutoInitialize.yes) payload;
alias X = typeof(payload.data[0]);
}
int main(string[] argv) {
return 0;
}
main.d(196): Error: std.typecons.RefCounted!(Payload,
cast(RefCountedAutoInitialize)1).RefCounted.refCountedPayload
called with argument types () matches both:
typecons.d(5241): std.typecons.RefCounted!(Payload,
cast(RefCountedAutoInitialize)1).RefCounted.refCountedPayload()
and:
typecons.d(5233): std.typecons.RefCounted!(Payload,
cast(RefCountedAutoInitialize)1).RefCounted.refCountedPayload()
More information about the Digitalmars-d
mailing list