On Friday, 14 December 2012 at 15:59:48 UTC, Mu wrote:
It works because "put" is defined for all input ranges as "write to first element and popFront".That makes more sense, thanks.So what happens is that for "regular" ranges std.range.put() gets used, while for arrays in RefAppender std.array.put() gets used, right?
Nope, you call the member function. std.array.RefAppender.put.Link to how "put" resolves. http://dlang.org/phobos/std_range.html#put