Garbage Collector?

Moritz Maxeiner via Digitalmars-d digitalmars-d at puremagic.com
Thu Apr 27 09:35:57 PDT 2017


On Thursday, 27 April 2017 at 15:50:56 UTC, Ben wrote:
> A few days ago i was reading this topic:
>
> https://news.ycombinator.com/item?id=14165198
>
> And the whole GC keeps coming up as a negative ( compared to 
> Rust ).

That's subjective, at best.
I see most of Rust's ownership mechanics in a negative light 
(love the lisp-inspired syntax, though), as they incur a severe 
productivity decrease while providing little safety benefit for 
/me/ over what I already have in D. But, as always, YMMV.

>
> From my understanding there has been a proposal DIP1000 to 
> address this issue.

You'll have to be more specific about what issue you're referring 
to. People not liking garbage collection? In any case, AFAIU 
DIP1000 was about more mechanically verifiable memory safety 
features when not using the GC.

>
> Is it possible to run D without the GC AND the standard library?

It is possible to run a D program without the GC only if you 
don't allocate using the GC. If you want to see D code that does 
allocate using the GC, the compiler flag `-vgc` is your friend 
(compile Phobos with `-vgc` for kicks). Currently, not all of 
Phobos is free of GC allocations, most notably exceptions (refer 
to [1] and similar topics)

[1] http://forum.dlang.org/thread/occ9kk$24va$1@digitalmars.com


More information about the Digitalmars-d mailing list