Weed wrote:
Christopher Wright пишет:
Weed wrote:
As a result, classes will be slow, or require more code to achieve
speeds comparable to C++.

That is actually a model of classes D harder than C++.
Yes, C++ offers more unsafe optimizations than D.


Straight to the point!
I am choosing unsafe but fast code. Unsafe at so much on how much is
unsafe any code on C++.

I think the issue is closed. :)

I spoke poorly. C++ enshrines unsafe optimizations as essential language features. D simply provides enough metaprogramming and low-level stuff that you can do it with a library. C++ gives you a revolver pointed at your foot, and you maneuver your target between the revolver and your foot. D gives you a kit to make a gun in 5 easy steps!!! and lets you point it at your foot if you want.

For instance, you can come up with templates that give you struct polymorphism. But you yourself said that that isn't a good idea, and that you should not use value types in a polymorphic manner.

Reply via email to