Future of memory management in D

Ola Fosheim Grøstad ola.fosheim.grostad at gmail.com
Thu Nov 18 15:09:39 UTC 2021


On Thursday, 18 November 2021 at 14:54:31 UTC, JN wrote:
> I don't know if C++ compatibility is a good direction. Most 
> modern languages try to distance themselves from C/C++ and only 
> offer C ABI interop for legacy software and popular libraries. 
> D always felt like trying to start from a clean slate and 
> minimize the dependencies on C/C++. By adding C++ 
> compatibility, whether we like it or not we will also inherit 
> negative things that are related with C++. D should stand on 
> its own as a language, rather than be a GC sidekick to make 
> code that works with C++.

Yes, but then the current C++ interop strategy should be unwound, 
otherwise you end up in that uncanny-valley situation where you 
are neither this nor that. You end up with the disadvantages of 
tracking C++ with limited benefits. Same for importC. You have to 
go all in to be taken seriously, not just dip your toes.

It is a difficult choice to make.

Coroutines are going to be more common over time in C++ code. 
Exceptions are less of a burden for libraries in C++ than it used 
to be.

So, long term strategic planning should say: do it, or pull out 
completely?



More information about the Digitalmars-d mailing list