Lets say I have 2 objects - object A and object B. Object A references Object B and object B references Object A.
- If Both Object A & Object B are out of ref of the code - how does Garbage collector know that it can be collected.
- How does Garbage collector deduce that any object is out of scope / ready for garbage collection?
- What about if Object A is not ref by our code but can still be independent. E.g. if it is a Form class then it can run on its own even if Object A is reinitialized to a new instance or specified null.