1
0
mirror of https://github.com/golang/go synced 2024-11-26 15:06:52 -07:00

context: fix doc tipo (s/timout/timeout)

Change-Id: Ib02b35887896eab418ba9dde764754538cb23b4f
Reviewed-on: https://go-review.googlesource.com/c/go/+/501277
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Run-TryBot: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@golang.org>
Auto-Submit: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
This commit is contained in:
Ian Lance Taylor 2023-06-06 10:57:50 -07:00 committed by Gopher Robot
parent e14937866e
commit fd353a1280

View File

@ -686,7 +686,7 @@ func WithTimeout(parent Context, timeout time.Duration) (Context, CancelFunc) {
}
// WithTimeoutCause behaves like [WithTimeout] but also sets the cause of the
// returned Context when the timout expires. The returned [CancelFunc] does
// returned Context when the timeout expires. The returned [CancelFunc] does
// not set the cause.
func WithTimeoutCause(parent Context, timeout time.Duration, cause error) (Context, CancelFunc) {
return WithDeadlineCause(parent, time.Now().Add(timeout), cause)