On 9/30/2016 7:31 PM, Andrei Alexandrescu wrote:
https://github.com/dlang/phobos/pull/4827 still allows that but specifies that
phobos algorithms are not required to. -- Andrei

A couple instances where a length may be longer than the address space:

1. large files
2. sequences of mathematically generated values

I don't see a particular advantage to restricting hasLength() to be size_t or ulong. Whether an algorithm requires the length to be within the addressable capabilities of the CPU or not should be up to the algorithm.

There is also cause for r.length to return an int even on a 64 bit system - it can be more efficient.

Reply via email to