https://issues.dlang.org/show_bug.cgi?id=15819
--- Comment #2 from Timothee Cour <[email protected]> --- reduced case: the issue goes away if we comment "private import std.array;" module bugs.bug_D20160321T233851; /+ dmd -unittest -main -run bugs/bug_D20160321T233851.d +/ import std.traits : isIterable, isNarrowString; import std.range : isInfinite,isInputRange; import std.array; unittest { EmitResult temp; alias Range = typeof(temp); static assert(isInputRange!Range); static assert(isIterable!Range && !isNarrowString!Range && !isInfinite!Range); // BUG:error: cannot resolve type for temp.array(Range)(Range r) if (isIterable!Range && !isNarrowString!Range && !isInfinite!Range) static assert(!is(typeof(temp.array))); static assert(is(typeof(array(temp)))); } private struct EmitResult { // comment this make things "normal" private import std.array; @property bool empty() { return true; } void popFront() { } @property int front() { return 0; } } --
