Template functions, can we make it more simple?
SteveGuo
steveguo at outlook.com
Fri Aug 2 15:00:10 PDT 2013
> He meant that when you only have a single token it is parsed as
> PARAMTYPE and not varname.
>
> EG:
>
> void foo(int);
Thanks for pointing out my misunderstanding.
But we can make a compiler which can "understand" what we want it
understand.
void foo(int); // this is just a declaration, not a definition
auto foo(a) // this is a definition, with a function body, they
are different
{
}
More information about the Digitalmars-d
mailing list