bearophile: > Having a return also helps to see templates as closer to compile-time > functions (changing few things there may be ways to merge the syntax of > templates with the syntax of compile time functions, reducing the complexity > of D).<
To write some templates as compile-time functions you may need to add a new type to D, named "type": type foo(type T) { return T[]; } That is the same as: template Foo(T) { alias T[] Foo; } Bye, bearophile