The following code works in 2.046: import std.traits;
template IterType(T) {
alias ReturnType!(
{
foreach(elem; T.init) {
return elem;
}
assert(0);
}) IterType;
}
alias IterType!(uint[]) foo;
In 2.047 beta it fails with the nonsensical error message:
test8.d(6): Error: delegate std.traits.__dgliteral1 cannot access frame
of function __dgliteral1
_______________________________________________ dmd-beta mailing list [email protected] http://lists.puremagic.com/mailman/listinfo/dmd-beta
