Another foreach idea.

Andrei Khropov andkhropov at nospam_mtu-net.ru
Sun Jun 18 13:19:30 PDT 2006


Fredrik Olsson wrote:

> I can take this as an opportunity to yet again voice my opinion for
> implementing ranges and sets as basic types of D. Templates are good and all,
> but as Walter writes himself on proper handling of floating point and
> infinity:  1. Building it in to the core language means the core language
> knows what a floating point infinity is. Being layered in templates,
> typedefs, casts, const bit patterns, etc., it doesn't know what it is, and is
> unlikely to give sensible error messages if misused.  2. A side effect of (1)
> is it is unlikely to be able to use it effectively in constant folding and
> other optimizations.
> 
> I think the same thing goes for ranges, ranged integer types and sets.

Absolutely agree. My vote for it!

-- 
AKhropov



More information about the Digitalmars-d mailing list