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….






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.