Every memory management system has a manual part, even the M$/Java GC has
element of it (the dreadful Disposable pattern to name one).
There is a huge difference however. ARC requires in general less coding for
the same result.
Less code in general is cheaper to develop, debug, read and maintain. It is
a simple business formula actually (and as businessman I need to calculate
this).
There is also the old saying "What is the only line of code where you can't
have a bug?" with the obvious answer - "The one you don't write." ;-) .
So on the balance sheet ARC is a cheaper and in general easier to maintain
form of manual memory management, and my experience with it (Mainly
interfaces - almost everything we do is interfaced nowadays), confirms that
100%.
With best regards,
Boian Mitov
-------------------------------------------------------
Mitov Software
www.mitov.com
-------------------------------------------------------
-----Original Message-----
From: Marco van de Voort
Sent: Sunday, September 21, 2014 3:58 AM
To: FPC developers' list
Subject: Re: [fpc-devel] Suggestion: reference counted objects
In our previous episode, Hans-Peter Diettrich said:
IMO Weak references should be reserved for users who accept possible
consequential problems, but should never be used in standard libraries.
At least I'd suggest to make weak references subject to an compiler
switch, so that every user has a chance to disable them in case of
trouble.
IMHO weak references trade one manual memory system in for a different
manual memory system.
The hard part of manual memory systems, figuring out how a complex dynamic
structure deallocates (that is usually tackled by having a bit of design and
thought go into it), remains.
_______________________________________________
fpc-devel maillist - fpc-devel@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel
_______________________________________________
fpc-devel maillist - fpc-devel@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel