Does GC actually run when you poke it? (C#) | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Does GC actually run when you poke it? (C#)

I know GC runs whenever it wants and I know how it works (kind of). I am wondering if the GC.Collect() actually does anything. Does it let it know that there are some resources on the heap that need managing? Or is it actually performing a full clean when using it?

5th Apr 2017, 7:35 PM
Iulian Bercea
Iulian Bercea - avatar
3 Answers
+ 2
i dont see any Poke method
5th Apr 2017, 7:45 PM
Edward
+ 1
not sure. i would read the documentation
5th Apr 2017, 7:40 PM
Edward
0
Sorry I had "poke" in my head for some reason.Edited now.
5th Apr 2017, 7:50 PM
Iulian Bercea
Iulian Bercea - avatar