Maybe D is right about GC after all !
bpr
brogoff at gmail.com
Sat Dec 23 19:35:41 UTC 2017
On Saturday, 23 December 2017 at 09:10:25 UTC, Walter Bright
wrote:
> On 12/22/2017 7:23 AM, Russel Winder wrote:
>> I think we are now in a world where Rust is the zero cost
>> abstraction
>> language to replace C and C++, except for those who are
>> determined to
>> stay with C++ and evolve it.
>
> Maybe it is. But that is not because D isn't up to the task.
> I've converted a large program from C to D (Digital Mars C++'s
> front end) with -betterC and it really is a zero cost
> abstraction. The memory safety benefits are there (DIP 1000),
> RAII is there, nested functions, array bounds checking,
> template metaprogramming, CTFE, etc.
Is it planned to add more (I'm thinking of exceptions, which I
guess means classes too) of full D into betterC? As I wrote
earlier, it should be possible to achieve some rough kind of
feature parity with modern C++.
I really do like Rust; I think it's a brilliant language. There
are domains that require zero cost abstractions that are
currently NOT covered well by Rust though; D's Mir library is
pushing into one of those.
> D as betterC really is a game changer, for anyone who cares to
> give it a try.
Yes, it really is.
I really wish that D had a performant fully precise GC, but I'm
beginning to think that is unlikely to ever happen. Maybe being a
betterModernC++ in that regard would be good enough?
More information about the Digitalmars-d
mailing list