Andrei Alexandrescu wrote:
void foo_templated(T...)(T args)
{
   Variant[args.length] dynatyped;
   foreach (i, arg; args) dynatyped[i] = arg;
   return foo(dynatyped);
}
void foo(Variant[] dynatyped...)
{
   ...
}

Andrei

Okay, that's a reasonable solution, except that it doesn't work with interfaces. I already submitted a bugzilla entry that you should be able to create a Variant[] from D varargs, but that still requires writing a wrapper function.

Reply via email to