Delphi ARC: Free versus DisposeOf (via: Ondrej Pokorny – Google+)
Posted by jpluimers on 2014/03/12
An interesting discussion about the Delphi ARC compilers and Free versus DisposeOf is at Ondrej Pokorny – Google+ – Just realized: For me the most dangerous thing in ARC is….
Like this:
Like Loading...
Related
This entry was posted on 2014/03/12 at 23:55 and is filed under Delphi, Delphi XE4, Delphi XE5, Development, Software Development.
You can follow any responses to this entry through the RSS 2.0 feed.
You can leave a response, or trackback from your own site.
dennis said
The biggest problem is: you can’t reuse your old code without either changing all .free to .disposeOf (I wouldn’t recommend that) or identify weak references (a lot of work to do) and tag them with [weak]. I still think that ARC doesn’t really help writing better code (except for reducing try finally statements). And I still don’t understand the decision why .free is not the same as .DisposeOf in the nextgen compiler: if you let ARC the memory stuff do then just don’t use .free at all, if you want to free an object now, just use .free (as usual)…..
jpluimers said
Very valid points. Thanks for making them.