|
GC.Collect (); // Force garbage collection on all generations-how does the foo object GC recognize it as garbage? In fact, after I call this sentence, the foo object is still alive.
Implementing the IDisposable interface, my Foo class is very simple, there is no resource to release, only the memory occupied by its foo itself, how to release it? |
|