diff options
author | Ian Lance Taylor <iant@golang.org> | 2018-07-06 17:06:55 -0700 |
---|---|---|
committer | Ian Lance Taylor <iant@golang.org> | 2018-07-09 23:40:50 +0000 |
commit | fb59bccef32780d9f94e5bd22344d514087efd07 (patch) | |
tree | 74705c56979ad93efaed39d70cd32709d83500ad /src/runtime/mfinal.go | |
parent | eab57b27f5460a7e6b87fff95ce2948b7812ce05 (diff) | |
download | go-fb59bccef32780d9f94e5bd22344d514087efd07.tar.gz go-fb59bccef32780d9f94e5bd22344d514087efd07.zip |
runtime: clarify SetFinalizer docs
Fixes #24480
Change-Id: I7db721fb71a17f07472ec7f216478e7887435639
Reviewed-on: https://go-review.googlesource.com/122557
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Diffstat (limited to 'src/runtime/mfinal.go')
-rw-r--r-- | src/runtime/mfinal.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/mfinal.go b/src/runtime/mfinal.go index 6ce0312712..a8c51e3e02 100644 --- a/src/runtime/mfinal.go +++ b/src/runtime/mfinal.go @@ -267,8 +267,8 @@ func runfinq() { // is not guaranteed to run, because there is no ordering that // respects the dependencies. // -// The finalizer for obj is scheduled to run at some arbitrary time after -// obj becomes unreachable. +// The finalizer is scheduled to run at some arbitrary time after the +// program can no longer reach the object to which obj points. // There is no guarantee that finalizers will run before a program exits, // so typically they are useful only for releasing non-memory resources // associated with an object during a long-running program. |