Destructors (or finalizers) are good for the language - but you will almost never use them. Basically you only need them if you have a direct pen on an unmanaged resource, and this is not only incredibly rare, but SafeHandleas a tiny level of indirection, this is in any case the best idea (which handles cleaning for you). See the Joe Duffy related blog for more information .
For what it's worth, I can't remember the last time I wrote the finalizer, except to test for some odd behavior or something else.
For most of the time, life is easier:
- Garbage collector can handle memory cleanup
- (, ) ,
using, , , . - ( - ,
IDisposable) , IDisposable. ( , . , , sealed, , , , .)