RFC: reference counted Throwable
Paulo Pinto via Digitalmars-d
digitalmars-d at puremagic.com
Fri Sep 19 23:28:13 PDT 2014
Am 20.09.2014 06:43, schrieb Andrei Alexandrescu:
> On 9/19/14, 7:20 PM, Walter Bright wrote:
>> On 9/19/2014 6:48 PM, Andrei Alexandrescu wrote:
>>> On 9/19/14, 6:18 PM, Walter Bright wrote:
>>>> Having a compiler switch to change the behavior of every module in
>>>> incompatible ways would be a disastrous balkanization. It has to be
>>>> done
>>>> in such a way that the ARC and the existing exceptions can coexist.
>>>
>>> Could you please elaborate why the disaster? -- Andrei
>>>
>>
>> 1. Every library for D will have to come in two versions. One which
>> works, and the other is likely untested. This will divide the D
>> community in half.
>
> I understand where you're coming from. And you're right that we're
> looking at an important change - as big as -m64 vs. -m32 or porting to a
> new platform. It's big. But it's needed, soon. And it would be, it seems
> to me, a mistake to approach this big change as a small change that we
> can sneak in.
>
> This judgment - that RC vs. GC would balkanize the community - has
> become a prejudice that is worth revisiting. Just trotting it out again
> won't do.
>
>> 2. RC and GC engender different styles of programming. The idea that one
>> can successfully switch between them with merely a compiler switch is a
>> fantasy. You cannot write non-trivial programs that function well and
>> pay no attention to how memory management is done.
>
> I think we're at a point where we owe it to ourselves to consider
> realizing the fantasy.
>
>
> Andrei
>
This is one of the reasons why the Objective-C GC failed.
Mixing Frameworks compiled with both modes never worked properly.
--
Paulo
More information about the Digitalmars-d
mailing list