Ref() marks the object as being attached to an event loop. * Refed objects will not be garbage collected, even if * all references are lost. */
| 90 | * all references are lost. |
| 91 | */ |
| 92 | virtual void Ref() { |
| 93 | assert(!persistent().IsEmpty()); |
| 94 | persistent().ClearWeak(); |
| 95 | refs_++; |
| 96 | } |
| 97 | |
| 98 | /* Unref() marks an object as detached from the event loop. This is its |
| 99 | * default state. When an object with a "weak" reference changes from |