reference cycle
Values that point to each other with counted references, so none of them is ever freed.
Rc values that own each other keep their strong counts above zero forever; the memory leaks (safely). Weak references, which don't count as owners, break the cycle.
Loading interactive…
Examples
If node
aholds anRctobandbholds one back toa, dropping both variables leaves each count at 1, so neither node is ever freed.
See also