--- Comment #17 from Andrei Alexandrescu <> 2011-07-22 
11:44:32 PDT ---
(In reply to comment #15)
> Say we have this:
> struct Foo
> {
>     int value;
>     alias value this;
> }
> If an "instance" of Foo is passed to a function taking variadic arguments then
> it's received as Foo and not int, correct? Why would an alias this with a 
> tuple
> behave any different. In that case you would have to manually expand it.

This is not only about variadic arguments, sorry for being confusing. It is
about the combinatorial explosion when overloading rules meet automatic
expansion. Again, please consider this example:

fun(t1, t2, t3, t4);

and consider:

* fun may have an arbitrary number of overloads
* Some or all of t1 through t4 may be tuples, some also including tuples of

The fact that there exists an algorithm to find an expansion (albeit in
potentially a long time) is little solace when we consider the complexity
inflicted on the human reader.

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to