Andrei's list of barriers to D adoption

poliklosio via Digitalmars-d digitalmars-d at puremagic.com
Mon Jun 6 13:28:47 PDT 2016


On Monday, 6 June 2016 at 15:06:49 UTC, Carl Vogel wrote:
> (...) Also, the idea that more people will adopt D if you just 
> "get rid of the GC" ignores the fact that you don't just "get 
> rid of the GC," you replace it with another memory management 
> scheme (manual, RAII, RC). If you replace all the parts of the 
> language and phobos that rely on GC with, e.g., a poor 
> implementation of RC, then you're just going to get another 
> round of complaints, and no real adoption.

I think you are going to get some adoption it you replace good GC 
with clunky RC.
The key difference is a call to a function that uses GC is 
incomplete: some of it will execute later, after the call has 
finished.
On the other hand a call to an equivalent function that uses RC 
has only local (in time) consequences: once you finished the 
call, it stopped executing. If it returned something that needs 
to be freed later, you know what it is.
Of course people can write arbitrarily messed up things like 
singletons etc. but I'm not counting those because good libraries 
are usually free of those.
This means you have control over all the OTHER code, however 
inefficient the call is.
Hence, the second is acceptable in low-latency code, but the 
first is not.



More information about the Digitalmars-d mailing list