www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Feasibility of a std.encoding.safeDecode overload for InputRanges?

Currently, std.encoding.safeDecode seems to only work on Random 
Access Ranges that have a .length property. (So essentially 
arrays and array-like objects), but I would very much like to be 
able to safeDecode strings that have lazy range-based processing 
applied to them (which often ends up with only an InputRange).

Given that throwing-decodes work just fine on input ranges, would 
it be possible to let safe decodes work for them as well?
Jun 20 2015