D Language 2.0

Leandro Lucarella llucax at gmail.com
Wed Jan 20 16:16:38 PST 2010


Andrei Alexandrescu, el 20 de enero a las 08:32 me escribiste:
> Leandro Lucarella wrote:
> >Again? RC is *not* -nogc, is -anothergc.
> 
> I agree. With reference counting, you'd be no worse than a C++
> project that decided to use refcounted smart pointers for all
> allocated objects. That sounds good to me.
> 
> >And reference counting won't do
> >the trick unless you add a backing GC to free cycles.
> 
> Well there are techniques for lifting cycles but really I think it
> wouldn't be bad if the user were given the possibility (e.g. weak
> pointers).
> 
> >What I mean about
> >-nogc is *no* GC, is "please, mr compiler, give me an error when a GC
> >facility is used".
> 
> I know. That could be another object.d implementation that would
> @disable certain functions. The nice part about refcounting is that
> for the most part you don't need to cripple the language.

But I don't think people that *really* need to be in full control would
see a RC GC as something tempting. As long as there is an option to
(easily) avoid the GC, I'm happy, if you want to provice an RC
implementation then, great. I can't see an RC implementation fitting very
well in D (because of slicing and other features, mostly the very same
features that makes the D GC very conservative and inefficient).

-- 
Leandro Lucarella (AKA luca)                     http://llucax.com.ar/
----------------------------------------------------------------------
GPG Key: 5F5A8D05 (F8CD F9A7 BF00 5431 4145  104C 949E BFB6 5F5A 8D05)
----------------------------------------------------------------------
He used to do surgery
On girls in the eighties
But gravity always wins



More information about the Digitalmars-d mailing list