On Sunday, February 24, 2013 13:02:46 monarch_dodra wrote: > My first reaction when I stumbled upon it actually. Then again, > can't the same be said about lambas? Technically, they *are* > templates, since the type is determined when they are actually > called. > > Also, when you say "alias", do you mean "pass as alias > parameter", or the actual "alias"?
Both. > Because templates can be > aliased un parametrized. > > import std.algorithm, std.stdio; > > void main() > { > alias map2 = map; > writeln(map2!"a * 2"([1, 2, 3])); > } Maybe the problem is when you try and partially instantiate them, but that's why some templated functions (like map) are a template wrapping a templated function rather than just being a straight templated function. - Jonathan M Davis