79707762

Date: 2025-07-20 06:03:27
Score: 2.5
Natty:
Report link

Your MyClass object is a structure containing the reference to the 2 event handlere, if you want that specific instance to be garbage collected you need to unsubscribe to both event handlers. If you require a manual process to ensure this, implement the IDispose interface and call that method, that then ensured that event handlers are all unsubscribed.

Reasons:
  • No code block (0.5):
  • Unregistered user (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Morten Bork