Performance penalty for using ranges

Timon Gehr timon.gehr at gmx.ch
Sun Aug 25 14:11:54 PDT 2013


On 08/25/2013 10:42 PM, Joseph Rushton Wakeling wrote:
>
>
>      foreach (immutable i; iota(0, n, 2)) { ... }
>
> ... but again, that will be slow compared to the for loop or a foreach
> across an interval.

Why would that be the case?



More information about the Digitalmars-d mailing list