https://issues.dlang.org/show_bug.cgi?id=15045

--- Comment #3 from Martin Nowak <[email protected]> ---
(In reply to Kenji Hara from comment #2)
> IMHO, it would be better to prevent forwarding some built-in special member
> names prefixed by double-underscore through alias this or opDispatch.
> 
> As we've already patched in library code like,
> 
>  https://github.com/D-Programming-Language/druntime/pull/1313
> 
> forwarding of __xpostblit and __xdtor are hardly useless.
> 
> From the dmd internal view, 
> the complete list of "no forward" members would be:
> 
> __ctor (Id.ctor)
> __dtor (Id.dtor)
> __xdtor (Id.__xdtor)
> __postblit (Id.postblit)
> __xpostblit (Id.__xpostblit)

Oh yes, that's a much better solution. The semantics of those builtin member
functions don't make sense with forwarding (through alias this or for
opDispatch) anyhow.

--

Reply via email to