D vs. C#

Ary Manzana ary at esperanto.org.ar
Fri Nov 24 03:01:03 PST 2006


Walter Bright escribió:
> Dave wrote:
>> I don't think D interfaces would have any less performance potential 
>> than any other language using interfaces (or even C++ MI)?
> 
> Since D interfaces are implemented just like C++ MI, there is no 
> performance difference between the two.

I wrote that because of the recent discusion about iterators. I copy and 
paste:

Bill Baxter said:
 > That's like C++'s way.  Iterator is basically a generalized pointer.
 > The other proposal is more like Java/Python/C#'s way, where the
 > iterator  is like a pointer that knows it's own limits.

Walter Bright said:
 > I think the C++ like way will be a lot more efficient, and I think it
 > will work.

So now I wonder what "a lot more efficient" means.

Some people (like me) think it's very hard to understand C++ iterator 
semantic, and it's also harder to implement your own iterator.  And if 
doing it that way dosen't improve your performance, then you are loosing 
easy development against a little better performance (which you can 
always have by not using iterators at all).



More information about the Digitalmars-d mailing list