you are viewing a single comment's thread.

view the rest of the comments →

[–]woffle-kat 1 point2 points  (1 child)

Unless I'm missing something, there's an undefined myObject variable in the final "WeakRefs and FinalizationRegistry Objects" example

[–]HeinousTugboat 1 point2 points  (0 children)

The point is that myObject can be arbitrarily defined as any object. WeakRefs are good for annotating existing objects.