import std.range;
import std.stdio;
struct S {
int a;
@disable this(this);
}
void main() {
writeln(isInputRange!(S[])); // Prints false
}
The reason, as far as I can tell, is that an input range requires that
we can do:
auto a = ir.front; // Assuming ir isn't empty
That doesn't work for non-copyable types, for obvious reasons.
With that said, that seems more like a deficiency in the input range
definition than anything. There is no reason we shouldn't be able to
iterator type operations over non-copyable types.
Shachar