Some dynamic dispatch to reduce template bloat

mist none at none.none
Tue Jan 22 03:38:55 PST 2013


On Tuesday, 22 January 2013 at 11:09:05 UTC, bearophile wrote:
> This "Dynamic dispatch" section of the Clay language 
> documentation shows a way to avoid some template bloat (that is 
> common in Clay):
>
> https://github.com/jckarter/clay/wiki/Avoiding-generic-programming-pitfalls
>
> Maybe it's possible to make that syntax&code shorter and 
> lighter.
>
> Bye,
> bearophile

May be I do not get it, but this can already be done in D. There 
is always a trade-off between template binary bloat and 
performance penalty of dynamic typing and suggested approach 
(make a templated light interface and code most function using  
dynamic typing) is not that uncommon one even in C++ world.


More information about the Digitalmars-d mailing list