circular reference detection, posible?
Posted: Mon Mar 11, 2019 9:44 pm
Hello madschi,
it is well known that circular references between interface objects cause memory leaks.
E.g:
Obj1 -> references Obj2
Obj2 -> references Obj1
Obj1, and Obj2 are interface objects, they will be released once their reference count reaches 0. This will never happen in this case, due to the circular reference.
As a consequence Obj1 and Obj2 are never freed.
If Obj1 and Obj2 hold references to many other objects, which themselves reference other objects you will just get a massive leak report. Finding the two objects which are causing the leak becomes a nightmare...
Would it be possible for you to detect such circular references in madExcept?
You can't imagine how useful that would be for us.... And I imagine for many others as well.
Looking forward to hear your response.
Thanks!
it is well known that circular references between interface objects cause memory leaks.
E.g:
Obj1 -> references Obj2
Obj2 -> references Obj1
Obj1, and Obj2 are interface objects, they will be released once their reference count reaches 0. This will never happen in this case, due to the circular reference.
As a consequence Obj1 and Obj2 are never freed.
If Obj1 and Obj2 hold references to many other objects, which themselves reference other objects you will just get a massive leak report. Finding the two objects which are causing the leak becomes a nightmare...
Would it be possible for you to detect such circular references in madExcept?
You can't imagine how useful that would be for us.... And I imagine for many others as well.
Looking forward to hear your response.
Thanks!