Where are we on getting rid of Nullable's alias this? Was that happening?
aliak
something at something.com
Thu May 30 14:39:05 UTC 2019
Just ran in to this awesome bug
import std;
struct Foo {
Nullable!string a;
}
void main() {
string a;
auto app = appender(&a);
formattedWrite(app, "%s", Foo());
}
Because this:
https://github.com/dlang/phobos/blob/master/std/format.d#L3448
Because "StringTypeOf!(Nullable!string) = Nullable!string()"
calls get implicitly, which assers :/
I'm not sure if there's a workaround. I remember there was talk
of removing alias this in Nullable? But I also remember there was
no consensus?
Cheers,
- Ali
More information about the Digitalmars-d
mailing list