This repository was archived by the owner on Jan 23, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -270,9 +270,12 @@ internal static int CollectionCount (int generation, bool getSpecialGCCount)
270
270
// thread. This isn't just about handles - it can happen with just
271
271
// about any finalizable resource.
272
272
//
273
- // Users should insert a call to this method near the end of a
274
- // method where they must keep an object alive for the duration of that
275
- // method, up until this method is called. Here is an example:
273
+ // Users should insert a call to this method right after the last line
274
+ // of their code where their code still needs the object to be kept alive.
275
+ // The object which reference is passed into this method will not
276
+ // be eligible for collection until the call to this method happens.
277
+ // Once the call to this method has happened the object may immediately
278
+ // become eligible for collection. Here is an example:
276
279
//
277
280
// "...all you really need is one object with a Finalize method, and a
278
281
// second object with a Close/Dispose/Done method. Such as the following
You can’t perform that action at this time.
0 commit comments