1
0
mirror of https://github.com/golang/go synced 2024-09-29 19:34:38 -06:00

all: fix misspellings

GitHub-Last-Rev: 468df242d0
GitHub-Pull-Request: golang/go#23935
Change-Id: If751ce3ffa3a4d5e00a3138211383d12cb6b23fc
Reviewed-on: https://go-review.googlesource.com/95577
Run-TryBot: Andrew Bonventre <andybons@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
This commit is contained in:
Shawn Smith 2018-02-20 20:50:20 +00:00 committed by Andrew Bonventre
parent ec62ee7f6d
commit d3beea8c52
14 changed files with 25 additions and 25 deletions

View File

@ -120,7 +120,7 @@ func arm64RegisterNumber(name string, n int16) (int16, bool) {
return 0, false return 0, false
} }
// ARM64RegisterExtension parses an ARM64 register with extension or arrangment. // ARM64RegisterExtension parses an ARM64 register with extension or arrangement.
func ARM64RegisterExtension(a *obj.Addr, ext string, reg, num int16, isAmount, isIndex bool) error { func ARM64RegisterExtension(a *obj.Addr, ext string, reg, num int16, isAmount, isIndex bool) error {
rm := uint32(reg) rm := uint32(reg)
if isAmount { if isAmount {
@ -222,7 +222,7 @@ func ARM64RegisterExtension(a *obj.Addr, ext string, reg, num int16, isAmount, i
return nil return nil
} }
// ARM64RegisterArrangement parses an ARM64 vector register arrangment. // ARM64RegisterArrangement parses an ARM64 vector register arrangement.
func ARM64RegisterArrangement(reg int16, name, arng string) (int64, error) { func ARM64RegisterArrangement(reg int16, name, arng string) (int64, error) {
var curQ, curSize uint16 var curQ, curSize uint16
if name[0] != 'V' { if name[0] != 'V' {

View File

@ -591,7 +591,7 @@ func (p *Parser) registerShift(name string, prefix rune) int64 {
} }
} }
// registerExtension parses a register with extension or arrangment. // registerExtension parses a register with extension or arrangement.
// There is known to be a register (current token) and an extension operator (peeked token). // There is known to be a register (current token) and an extension operator (peeked token).
func (p *Parser) registerExtension(a *obj.Addr, name string, prefix rune) { func (p *Parser) registerExtension(a *obj.Addr, name string, prefix rune) {
if prefix != 0 { if prefix != 0 {

View File

@ -30,7 +30,7 @@ import (
// of the 2-to-the-(J-1) serial numbers. // of the 2-to-the-(J-1) serial numbers.
// For each generated function a compact summary is also // For each generated function a compact summary is also
// created so that the generated funtion can be simulated // created so that the generated function can be simulated
// with a simple interpreter to sanity check the behavior of // with a simple interpreter to sanity check the behavior of
// the compiled code. // the compiled code.

View File

@ -915,7 +915,7 @@ func commute1(m string, cnt map[string]int, arch arch) []string {
panic("couldn't find first two args of commutative op " + s[0]) panic("couldn't find first two args of commutative op " + s[0])
} }
if cnt[s[idx0]] == 1 && cnt[s[idx1]] == 1 || s[idx0] == s[idx1] && cnt[s[idx0]] == 2 { if cnt[s[idx0]] == 1 && cnt[s[idx1]] == 1 || s[idx0] == s[idx1] && cnt[s[idx0]] == 2 {
// When we have (Add x y) with no ther uses of x and y in the matching rule, // When we have (Add x y) with no other uses of x and y in the matching rule,
// then we can skip the commutative match (Add y x). // then we can skip the commutative match (Add y x).
commutative = false commutative = false
} }

View File

@ -56,7 +56,7 @@ func insertLoopReschedChecks(f *Func) {
// are present in the graph, initially with trivial inputs. // are present in the graph, initially with trivial inputs.
// 4. Record all to-be-modified uses of mem; // 4. Record all to-be-modified uses of mem;
// apply modifications (split into two steps to simplify and // apply modifications (split into two steps to simplify and
// avoided nagging order-dependences). // avoided nagging order-dependencies).
// 5. Rewrite backedges to include reschedule check, // 5. Rewrite backedges to include reschedule check,
// and modify destination phi function appropriately with new // and modify destination phi function appropriately with new
// definitions for mem. // definitions for mem.

View File

@ -129,7 +129,7 @@ Go Assembly for ARM64 Reference Manual
VSUB: Sub (scalar) VSUB: Sub (scalar)
VSUB <Vm>, <Vn>, <Vd> VSUB <Vm>, <Vn>, <Vd>
Subtract low 64-bit element in <Vm> from the correponding element in <Vn>, Subtract low 64-bit element in <Vm> from the corresponding element in <Vn>,
place the result into low 64-bit element of <Vd>. place the result into low 64-bit element of <Vd>.
VUADDLV: Unsigned sum Long across Vector. VUADDLV: Unsigned sum Long across Vector.

View File

@ -457,7 +457,7 @@ func parseArmAttributes(e binary.ByteOrder, data []byte) (found bool, ehdrFlags
// On ARM systems, Load will attempt to determine what ELF header flags to // On ARM systems, Load will attempt to determine what ELF header flags to
// emit by scanning the attributes in the ELF file being loaded. The // emit by scanning the attributes in the ELF file being loaded. The
// parameter initEhdrFlags contains the current header flags for the output // parameter initEhdrFlags contains the current header flags for the output
// object, and the returnd ehdrFlags contains what this Load function computes. // object, and the returned ehdrFlags contains what this Load function computes.
// TODO: find a better place for this logic. // TODO: find a better place for this logic.
func Load(arch *sys.Arch, syms *sym.Symbols, f *bio.Reader, pkg string, length int64, pn string, initEhdrFlags uint32) (textp []*sym.Symbol, ehdrFlags uint32, err error) { func Load(arch *sys.Arch, syms *sym.Symbols, f *bio.Reader, pkg string, length int64, pn string, initEhdrFlags uint32) (textp []*sym.Symbol, ehdrFlags uint32, err error) {
errorf := func(str string, args ...interface{}) ([]*sym.Symbol, uint32, error) { errorf := func(str string, args ...interface{}) ([]*sym.Symbol, uint32, error) {

View File

@ -70,7 +70,7 @@ const (
// and for constructing the global offset table when internally linking a dynamic // and for constructing the global offset table when internally linking a dynamic
// executable. // executable.
// //
// TOOD(mwhudson): perhaps a better name for this is AttrNonGoSymbol. // TODO(mwhudson): perhaps a better name for this is AttrNonGoSymbol.
AttrSubSymbol AttrSubSymbol
// AttrContainer is set on text symbols that are present as the .Outer for some // AttrContainer is set on text symbols that are present as the .Outer for some
// other symbol. // other symbol.

View File

@ -608,7 +608,7 @@ func TestUnmarshalToLargeCoordinates(t *testing.T) {
copy(invalidX[33:], y.Bytes()) copy(invalidX[33:], y.Bytes())
if X, Y := Unmarshal(curve, invalidX); X != nil || Y != nil { if X, Y := Unmarshal(curve, invalidX); X != nil || Y != nil {
t.Errorf("Unmarshal accpets invalid X coordinate") t.Errorf("Unmarshal accepts invalid X coordinate")
} }
// This is a point on the curve with a small y value, small enough that we can add p and still be within 32 bytes. // This is a point on the curve with a small y value, small enough that we can add p and still be within 32 bytes.
@ -625,6 +625,6 @@ func TestUnmarshalToLargeCoordinates(t *testing.T) {
copy(invalidY[33:], y.Bytes()) copy(invalidY[33:], y.Bytes())
if X, Y := Unmarshal(curve, invalidY); X != nil || Y != nil { if X, Y := Unmarshal(curve, invalidY); X != nil || Y != nil {
t.Errorf("Unmarshal accpets invalid Y coordinate") t.Errorf("Unmarshal accepts invalid Y coordinate")
} }
} }

View File

@ -47,7 +47,7 @@ const (
// name constraints, but leaf certificate contains a name of an // name constraints, but leaf certificate contains a name of an
// unsupported or unconstrained type. // unsupported or unconstrained type.
UnconstrainedName UnconstrainedName
// TooManyConstraints results when the number of comparision operations // TooManyConstraints results when the number of comparison operations
// needed to check a certificate exceeds the limit set by // needed to check a certificate exceeds the limit set by
// VerifyOptions.MaxConstraintComparisions. This limit exists to // VerifyOptions.MaxConstraintComparisions. This limit exists to
// prevent pathological certificates can consuming excessive amounts of // prevent pathological certificates can consuming excessive amounts of
@ -185,7 +185,7 @@ type VerifyOptions struct {
KeyUsages []ExtKeyUsage KeyUsages []ExtKeyUsage
// MaxConstraintComparisions is the maximum number of comparisons to // MaxConstraintComparisions is the maximum number of comparisons to
// perform when checking a given certificate's name constraints. If // perform when checking a given certificate's name constraints. If
// zero, a sensible default is used. This limit prevents pathalogical // zero, a sensible default is used. This limit prevents pathological
// certificates from consuming excessive amounts of CPU time when // certificates from consuming excessive amounts of CPU time when
// validating. // validating.
MaxConstraintComparisions int MaxConstraintComparisions int

View File

@ -1375,7 +1375,7 @@ func TestInvalidNilValues(t *testing.T) {
err = conn.QueryRowContext(ctx, "SELECT|people|bdate|age=?", 1).Scan(tt.input) err = conn.QueryRowContext(ctx, "SELECT|people|bdate|age=?", 1).Scan(tt.input)
if err == nil { if err == nil {
t.Fatal("expected error when querying nil column, but suceeded") t.Fatal("expected error when querying nil column, but succeeded")
} }
if err.Error() != tt.expectedError { if err.Error() != tt.expectedError {
t.Fatalf("Expected error: %s\nReceived: %s", tt.expectedError, err.Error()) t.Fatalf("Expected error: %s\nReceived: %s", tt.expectedError, err.Error())

View File

@ -40,7 +40,7 @@ func TestEscape(t *testing.T) {
}{ }{
F: false, F: false,
T: true, T: true,
C: "<Cincinatti>", C: "<Cincinnati>",
G: "<Goodbye>", G: "<Goodbye>",
H: "<Hello>", H: "<Hello>",
A: []string{"<a>", "<b>"}, A: []string{"<a>", "<b>"},
@ -61,7 +61,7 @@ func TestEscape(t *testing.T) {
{ {
"if", "if",
"{{if .T}}Hello{{end}}, {{.C}}!", "{{if .T}}Hello{{end}}, {{.C}}!",
"Hello, &lt;Cincinatti&gt;!", "Hello, &lt;Cincinnati&gt;!",
}, },
{ {
"else", "else",
@ -71,17 +71,17 @@ func TestEscape(t *testing.T) {
{ {
"overescaping1", "overescaping1",
"Hello, {{.C | html}}!", "Hello, {{.C | html}}!",
"Hello, &lt;Cincinatti&gt;!", "Hello, &lt;Cincinnati&gt;!",
}, },
{ {
"overescaping2", "overescaping2",
"Hello, {{html .C}}!", "Hello, {{html .C}}!",
"Hello, &lt;Cincinatti&gt;!", "Hello, &lt;Cincinnati&gt;!",
}, },
{ {
"overescaping3", "overescaping3",
"{{with .C}}{{$msg := .}}Hello, {{$msg}}!{{end}}", "{{with .C}}{{$msg := .}}Hello, {{$msg}}!{{end}}",
"Hello, &lt;Cincinatti&gt;!", "Hello, &lt;Cincinnati&gt;!",
}, },
{ {
"assignment", "assignment",
@ -181,7 +181,7 @@ func TestEscape(t *testing.T) {
{ {
"urlBranchConflictMoot", "urlBranchConflictMoot",
`<a href="{{if .T}}/foo?a={{else}}/bar#{{end}}{{.C}}">`, `<a href="{{if .T}}/foo?a={{else}}/bar#{{end}}{{.C}}">`,
`<a href="/foo?a=%3cCincinatti%3e">`, `<a href="/foo?a=%3cCincinnati%3e">`,
}, },
{ {
"jsStrValue", "jsStrValue",
@ -237,7 +237,7 @@ func TestEscape(t *testing.T) {
"jsStrNotUnderEscaped", "jsStrNotUnderEscaped",
"<button onclick='alert({{.C | urlquery}})'>", "<button onclick='alert({{.C | urlquery}})'>",
// URL escaped, then quoted for JS. // URL escaped, then quoted for JS.
`<button onclick='alert(&#34;%3CCincinatti%3E&#34;)'>`, `<button onclick='alert(&#34;%3CCincinnati%3E&#34;)'>`,
}, },
{ {
"jsRe", "jsRe",
@ -405,7 +405,7 @@ func TestEscape(t *testing.T) {
{ {
"HTML comment", "HTML comment",
"<b>Hello, <!-- name of world -->{{.C}}</b>", "<b>Hello, <!-- name of world -->{{.C}}</b>",
"<b>Hello, &lt;Cincinatti&gt;</b>", "<b>Hello, &lt;Cincinnati&gt;</b>",
}, },
{ {
"HTML comment not first < in text node.", "HTML comment not first < in text node.",
@ -445,7 +445,7 @@ func TestEscape(t *testing.T) {
{ {
"Split HTML comment", "Split HTML comment",
"<b>Hello, <!-- name of {{if .T}}city -->{{.C}}{{else}}world -->{{.W}}{{end}}</b>", "<b>Hello, <!-- name of {{if .T}}city -->{{.C}}{{else}}world -->{{.W}}{{end}}</b>",
"<b>Hello, &lt;Cincinatti&gt;</b>", "<b>Hello, &lt;Cincinnati&gt;</b>",
}, },
{ {
"JS line comment", "JS line comment",

View File

@ -179,7 +179,7 @@ func (b *blockReader) Read(p []byte) (int, error) {
// following the end of LZW data, the very next sub-block must be the block // following the end of LZW data, the very next sub-block must be the block
// terminator. If the very end of LZW data happened to fill one sub-block, at // terminator. If the very end of LZW data happened to fill one sub-block, at
// most one more sub-block of length 1 may exist before the block-terminator. // most one more sub-block of length 1 may exist before the block-terminator.
// These accomodations allow us to support GIFs created by less strict encoders. // These accommodations allow us to support GIFs created by less strict encoders.
// See https://golang.org/issue/16146. // See https://golang.org/issue/16146.
func (b *blockReader) close() error { func (b *blockReader) close() error {
if b.err == io.EOF { if b.err == io.EOF {

View File

@ -617,7 +617,7 @@ func (z *Int) lehmerGCD(a, b *Int) *Int {
B.Add(r, w) B.Add(r, w)
} else { } else {
// single-digit calculations failed to simluate any quotients // single-digit calculations failed to simulate any quotients
// do a standard Euclidean step // do a standard Euclidean step
t.Rem(A, B) t.Rem(A, B)
A, B, t = B, t, A A, B, t = B, t, A