https://issues.dlang.org/show_bug.cgi?id=14858
Issue ID: 14858
Summary: spurious "Error: overload alias 'foo' is not a
variable" when overloading template and non-template
via aliases
Product: D
Version: D2
Hardware: x86_64
OS: Linux
Status: NEW
Keywords: rejects-valid
Severity: normal
Priority: P1
Component: dmd
Assignee: [email protected]
Reporter: [email protected]
Reported by vitus to D.learn:
http://forum.dlang.org/post/[email protected]
----
void foo()(){}
void bar(int){}
alias foobar = foo;
alias foobar = bar;
void main()
{
foobar(1); /* Error: overload alias 'foo' is not a variable */
}
----
Works when when the call has a leading dot:
----
.foobar(1);
----
Works when the order of the aliases is switched:
----
alias foobar = bar;
alias foobar = foo;
----
--