Skip to content

Commit 67ddae8

Browse files
committed
all: use one 'l' when cancelling everywhere except Solaris
Fixes #11626. Change-Id: I1b70c0844473c3b57a53d7cca747ea5cdc68d232 Reviewed-on: https://go-review.googlesource.com/14526 Run-TryBot: Rob Pike <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-by: Brad Fitzpatrick <[email protected]>
1 parent f4f0344 commit 67ddae8

File tree

9 files changed

+14
-14
lines changed

9 files changed

+14
-14
lines changed

misc/cgo/test/issue6997_linux.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
// license that can be found in the LICENSE file.
44

55
// Test that pthread_cancel works as expected
6-
// (NPTL uses SIGRTMIN to implement thread cancellation)
6+
// (NPTL uses SIGRTMIN to implement thread cancelation)
77
// See https://golang.org/issue/6997
88
package cgotest
99

@@ -32,7 +32,7 @@ func test6997(t *testing.T) {
3232
select {
3333
case r = <-c:
3434
if r == 0 {
35-
t.Error("pthread finished but wasn't cancelled??")
35+
t.Error("pthread finished but wasn't canceled??")
3636
}
3737
case <-time.After(30 * time.Second):
3838
t.Error("hung in pthread_cancel/pthread_join")

src/cmd/compile/internal/big/float.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1272,7 +1272,7 @@ func (z *Float) usub(x, y *Float) {
12721272
ex = ey
12731273
}
12741274

1275-
// operands may have cancelled each other out
1275+
// operands may have canceled each other out
12761276
if len(z.mant) == 0 {
12771277
z.acc = Exact
12781278
z.form = zero

src/math/big/float.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1272,7 +1272,7 @@ func (z *Float) usub(x, y *Float) {
12721272
ex = ey
12731273
}
12741274

1275-
// operands may have cancelled each other out
1275+
// operands may have canceled each other out
12761276
if len(z.mant) == 0 {
12771277
z.acc = Exact
12781278
z.form = zero

src/math/cmplx/sqrt.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ import "math"
4040
// 1/2
4141
// Im w = [ (r - x)/2 ] .
4242
//
43-
// Cancellation error in r-x or r+x is avoided by using the
43+
// Cancelation error in r-x or r+x is avoided by using the
4444
// identity 2 Re w Im w = y.
4545
//
4646
// Note that -w is also a square root of z. The root chosen

src/math/j0.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ package math
3838
// = 1/sqrt(2) * (cos(x) + sin(x))
3939
// sin(x0) = sin(x)cos(pi/4)-cos(x)sin(pi/4)
4040
// = 1/sqrt(2) * (sin(x) - cos(x))
41-
// (To avoid cancellation, use
41+
// (To avoid cancelation, use
4242
// sin(x) +- cos(x) = -cos(2x)/(sin(x) -+ cos(x))
4343
// to compute the worse one.)
4444
//
@@ -188,7 +188,7 @@ func Y0(x float64) float64 {
188188
// = 1/sqrt(2) * (sin(x) + cos(x))
189189
// sin(x0) = sin(x)cos(3pi/4)-cos(x)sin(3pi/4)
190190
// = 1/sqrt(2) * (sin(x) - cos(x))
191-
// To avoid cancellation, use
191+
// To avoid cancelation, use
192192
// sin(x) +- cos(x) = -cos(2x)/(sin(x) -+ cos(x))
193193
// to compute the worse one.
194194

src/math/j1.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ package math
3939
// = 1/sqrt(2) * (sin(x) - cos(x))
4040
// sin(x1) = sin(x)cos(3pi/4)-cos(x)sin(3pi/4)
4141
// = -1/sqrt(2) * (sin(x) + cos(x))
42-
// (To avoid cancellation, use
42+
// (To avoid cancelation, use
4343
// sin(x) +- cos(x) = -cos(2x)/(sin(x) -+ cos(x))
4444
// to compute the worse one.)
4545
//
@@ -197,7 +197,7 @@ func Y1(x float64) float64 {
197197
// = 1/sqrt(2) * (sin(x) - cos(x))
198198
// sin(x0) = sin(x)cos(3pi/4)-cos(x)sin(3pi/4)
199199
// = -1/sqrt(2) * (cos(x) + sin(x))
200-
// To avoid cancellation, use
200+
// To avoid cancelation, use
201201
// sin(x) +- cos(x) = -cos(2x)/(sin(x) -+ cos(x))
202202
// to compute the worse one.
203203

src/net/fd_windows.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ func (s *ioSrv) ExecIO(o *operation, name string, submit func(o *operation) erro
208208
s.req <- ioSrvReq{o, nil}
209209
<-o.errc
210210
}
211-
// Wait for cancellation to complete.
211+
// Wait for cancelation to complete.
212212
fd.pd.WaitCanceled(int(o.mode))
213213
if o.errno != 0 {
214214
err = syscall.Errno(o.errno)
@@ -217,8 +217,8 @@ func (s *ioSrv) ExecIO(o *operation, name string, submit func(o *operation) erro
217217
}
218218
return 0, err
219219
}
220-
// We issued cancellation request. But, it seems, IO operation succeeded
221-
// before cancellation request run. We need to treat IO operation as
220+
// We issued a cancelation request. But, it seems, IO operation succeeded
221+
// before the cancelation request run. We need to treat the IO operation as
222222
// succeeded (the bytes are actually sent/recv from network).
223223
return int(o.qty), nil
224224
}

src/net/http/httputil/reverseproxy_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ func TestReverseProxyFlushInterval(t *testing.T) {
225225
}
226226
}
227227

228-
func TestReverseProxyCancellation(t *testing.T) {
228+
func TestReverseProxyCancelation(t *testing.T) {
229229
if runtime.GOOS == "plan9" {
230230
t.Skip("skipping test; see https://golang.org/issue/9554")
231231
}

src/runtime/signal_solaris.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ var sigtable = [...]sigTabT{
4646
/* 33 */ {_SigNotify, "SIGLWP: reserved signal no longer used by"},
4747
/* 34 */ {_SigNotify, "SIGFREEZE: special signal used by CPR"},
4848
/* 35 */ {_SigNotify, "SIGTHAW: special signal used by CPR"},
49-
/* 36 */ {0, "SIGCANCEL: reserved signal for thread cancellation"},
49+
/* 36 */ {0, "SIGCANCEL: reserved signal for thread cancellation"}, // Oracle's spelling of cancelation.
5050
/* 37 */ {_SigNotify, "SIGLOST: resource lost (eg, record-lock lost)"},
5151
/* 38 */ {_SigNotify, "SIGXRES: resource control exceeded"},
5252
/* 39 */ {_SigNotify, "SIGJVM1: reserved signal for Java Virtual Machine"},

0 commit comments

Comments
 (0)