Increasing performance with static polymorphism (and other neat tricks) - blog post

Joakim joakim at airpost.net
Tue Apr 1 03:27:35 PDT 2014


On Monday, 31 March 2014 at 23:57:09 UTC, srean wrote:
> Can't the destructor issue of scopebuffer be mitigated by using
>
>       hasElaborateDestructor( )
>
> For instance have two versions one with a destructor for non POD
> and another without. The compiler dispatches to the appropriate
> one at compile time. There should not be any loss in 
> performance.

Andrei suggested something similar on github a couple weeks ago:

https://github.com/D-Programming-Language/phobos/pull/2014#issuecomment-37947056


More information about the Digitalmars-d mailing list