Is it possible to detect garbage collection on a custom struct?

You are looking for a finalizer: ?finalizer

3 Likes