Automatic return type covariance for functions that return this?

bearophile bearophileHUGS at lycos.com
Sat Sep 15 16:09:36 PDT 2012


Andrej Mitrovic:

> I saw this
> static cast thingy laying around somewhere:
>
> auto static_cast(T,U)(U source)
> {
>     return cast(T)(cast(void*)source);
> }

Maybe you meant:
http://d.puremagic.com/issues/show_bug.cgi?id=5559

Bye,
bearophile


More information about the Digitalmars-d-learn mailing list