Iterators and Ranges: Comparing C++ to D to Rust

Petar Petar
Tue Jun 15 16:23:18 UTC 2021


On Tuesday, 15 June 2021 at 14:31:31 UTC, Dukc wrote:
> On Tuesday, 15 June 2021 at 13:25:23 UTC, Paulo Pinto wrote:
>>
>> Actually the real problem is that people think it is not fast 
>> enough, based on urban myths without touching any kind of 
>> profiling tools, or measuring it against the project hard 
>> deadlines.
>>
>> More often than not, it is already fast enough, unless we are 
>> talking about winning micro-benchmarks games.
>
> This is true, but what if the benchmarks show you do need to 
> optimize? You need to avoid systemically slow designs in 
> advance or you run the risk of having to rewrite the whole 
> program.
>
> Now, you absolutely can design your program in [insert 
> non-system language] so that it can be optimized as needed. But 
> I believe Petar was arguing that certain kinds of inefficient 
> iterator APIs discourage doing so.

Yes, that's a good summary.


More information about the Digitalmars-d mailing list