[Issue 7553] auto template param triggers mixin conflict
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Tue Jul 29 17:59:27 PDT 2014
https://issues.dlang.org/show_bug.cgi?id=7553
hsteoh at quickfur.ath.cx changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
CC| |hsteoh at quickfur.ath.cx
Resolution|--- |WORKSFORME
--- Comment #1 from hsteoh at quickfur.ath.cx ---
Seems to work in git HEAD, after fixing some errors in the code:
------
template Foo(){
struct Range{
}
}
template Biz(){
struct Range{
}
}
class Bar{
mixin Foo!() index0;
mixin Biz!() index1;
auto to_range(Range)(Range r)
{
return r; // have to return something for r2 to have non-void type
}
}
void main(){
auto r2 =Bar.init.to_range(1); // have to use .init to pass actual value to
to_range
}
------
With these changes, it can compile successfully; no more conflict errors. So
looks like the bug has been fixed in git HEAD.
--
More information about the Digitalmars-d-bugs
mailing list