Comment #0 by default_357-line — 2020-09-16T14:58:02Z
Consider the following two files:
```
--- test2.d
void act1(T : void)() { }
void act2(T : int)() { }
void call(alias fn, T)()
{
alias instance = fn!T();
instance(); // this works
fn!T(); // this does not!
}
--- test.d
import test2 : act = act1, act = act2, call;
void main()
{
act!int(); // this works
act!void(); // this works, so act is an overload set
call!(act, void); // but not this?
call!(act, int); // and not this either!
}
```
https://run.dlang.io/is/gxaPuX
Even though we can call `act` in test with both supported types, we cannot call it in `test2` with either. We get the error "none of the overloads of `act` are callable using argument types `!(Struct)()` or "`!(int)()` respectively. If the function is aliased beforehand, it works.
Comment #1 by robert.schadek — 2024-12-13T19:11:35Z