The new, new phobos sneak preview
Michel Fortin
michel.fortin at michelf.com
Mon Apr 13 02:54:47 PDT 2009
On 2009-04-13 04:20:32 -0400, Lars Kyllingstad
<public at kyllingen.NOSPAMnet> said:
> ...except that my example, and indeed any range produced by sequence,
> recurrence, etc. are bounded at one end. Thus the term "infinite range"
> is more precise, and fits in well with the mathematical terms "infinite
> series" and "infinite sequence". Just not "infinite" alone. :)
Indeed.
And since the thing in the argument is indeed a range, I'd use infinite
alone in the function name. That way, if you build something which
isn't a range but still represent a sequence, it can have this part of
the interface in common.
In a language that doesn't support overloading (such as C or
Objective-C), I'd be in favor of keeping the "range" suffix to
differenciate the function from other functions applying to other kinds
of arguments. In D, or C++, which support overloading, I'm in favor of
skipping the argument type suffix.
--
Michel Fortin
michel.fortin at michelf.com
http://michelf.com/
More information about the Digitalmars-d
mailing list