We need better documentation for functions with ranges and templates

ZombineDev via Digitalmars-d digitalmars-d at puremagic.com
Wed Dec 16 23:57:20 PST 2015


On Thursday, 17 December 2015 at 07:19:04 UTC, Jon D wrote:
> On Monday, 14 December 2015 at 19:04:46 UTC, bachmeier wrote:
>> Something has to be done with the documentation for Phobos 
>> functions that involve ranges and templates.
>>
> Many useful ideas in this thread. One I don't recall seeing - a 
> standard way to denote whether a routine is lazy or eager. I'm 
> finding this to be a key piece of information. Many standard 
> library routines document this in the description, but presence 
> and presentation is not very consistent. It'd be nice to have 
> this presented in a standard way for routines operating on 
> ranges.
>
> --Jon

Yes this something important that is missing. It is currently up 
to the documentation of a particular function to explain this. I 
think originally std.range was supposed to be lazy and 
std.algorithm - eager, but currently it's not a clear cut. Also 
in different contexts you may need a lazy version of an eager 
algorithm and vice-versa.


More information about the Digitalmars-d mailing list