From 856238615deb2158f3868e7475817b3a2d6b2513 Mon Sep 17 00:00:00 2001 From: Jes Cok Date: Mon, 3 Nov 2025 18:47:25 +0000 Subject: [PATCH] runtime: amend doc for setPinned Change-Id: I9c5a8f8a031e368bda312c830dc266f5986e8b1a GitHub-Last-Rev: 23145e8fdbc020ae17503e3abe4fe230ba1082ef GitHub-Pull-Request: golang/go#76160 Reviewed-on: https://go-review.googlesource.com/c/go/+/717341 Reviewed-by: Keith Randall Auto-Submit: Keith Randall Reviewed-by: Keith Randall LUCI-TryBot-Result: Go LUCI Reviewed-by: Michael Pratt --- src/runtime/pinner.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/runtime/pinner.go b/src/runtime/pinner.go index 424dd065ef..dad14a4d09 100644 --- a/src/runtime/pinner.go +++ b/src/runtime/pinner.go @@ -143,8 +143,8 @@ func isPinned(ptr unsafe.Pointer) bool { } // setPinned marks or unmarks a Go pointer as pinned, when the ptr is a Go pointer. -// It will be ignored while try to pin a non-Go pointer, -// and it will be panic while try to unpin a non-Go pointer, +// It will be ignored while trying to pin a non-Go pointer. +// It will panic while trying to unpin a non-Go pointer, // which should not happen in normal usage. func setPinned(ptr unsafe.Pointer, pin bool) bool { span := spanOfHeap(uintptr(ptr)) -- 2.52.0