Possible bug of "missing matching more than one candidate" in overload set

monkyyy crazymonkyyy at gmail.com
Fri Feb 13 14:19:20 UTC 2026


On Friday, 13 February 2026 at 12:27:54 UTC, user1234 wrote:
> On Friday, 13 February 2026 at 12:25:30 UTC, user1234 wrote:
>> Note that the program compiles when you remove one or the 
>> other `f`.
>
> To be clear, I meant if you remove the static assertion, e.g
>
> ```d
> alias Seq(T...) = T;
>
> void f1()(){}
> void f2(T...)(){}
>
> void main()
> {
>     f1!(Seq!())();
>     f2!(Seq!())();
> }
> ```
>
> which proves that in the first program, both `f` match.

Behavior looks correct to me, auto flattening and specialization 
are both written down in the spec somewhere.

```d
alias Seq(T...) = T;
alias foo=Seq!();
alias bar=Seq!(Seq!(Seq!(Seq!())));

static assert(is(foo==bar));
```


More information about the Digitalmars-d-learn mailing list