From 5b82db07426dbac2c94df2e3a85e83f3026c088c Mon Sep 17 00:00:00 2001 From: Ainar Garipov Date: Sun, 8 Sep 2019 19:10:01 +0300 Subject: [PATCH] go/analysis: fix typos Change-Id: I07235ffba66bf0f7ef0e1917c6f711d317c9ae02 Reviewed-on: https://go-review.googlesource.com/c/tools/+/194139 Reviewed-by: Toshihiro Shiino Reviewed-by: Brad Fitzpatrick --- go/analysis/internal/facts/facts.go | 2 +- go/analysis/passes/cgocall/cgocall.go | 4 ++-- go/analysis/passes/errorsas/errorsas.go | 2 +- go/analysis/validate.go | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/go/analysis/internal/facts/facts.go b/go/analysis/internal/facts/facts.go index dcd4f4da81..bcc6bd8e7d 100644 --- a/go/analysis/internal/facts/facts.go +++ b/go/analysis/internal/facts/facts.go @@ -29,7 +29,7 @@ // The notion of "exportedness" that matters here is that of the // compiler. According to the language spec, a method pkg.T.f is // unexported simply because its name starts with lowercase. But the -// compiler must nonethless export f so that downstream compilations can +// compiler must nonetheless export f so that downstream compilations can // accurately ascertain whether pkg.T implements an interface pkg.I // defined as interface{f()}. Exported thus means "described in export // data". diff --git a/go/analysis/passes/cgocall/cgocall.go b/go/analysis/passes/cgocall/cgocall.go index 1e4fac8595..d499f3c329 100644 --- a/go/analysis/passes/cgocall/cgocall.go +++ b/go/analysis/passes/cgocall/cgocall.go @@ -107,7 +107,7 @@ func checkCgo(fset *token.FileSet, f *ast.File, info *types.Info, reportf func(t // cgo files of a package (those that import "C"). Such files are not // Go, so there may be gaps in type information around C.f references. // -// This checker was initially written in vet to inpect raw cgo source +// This checker was initially written in vet to inspect raw cgo source // files using partial type information. However, Analyzers in the new // analysis API are presented with the type-checked, "cooked" Go ASTs // resulting from cgo-processing files, so we must choose between @@ -133,7 +133,7 @@ func checkCgo(fset *token.FileSet, f *ast.File, info *types.Info, reportf func(t // func (T) f(int) string { ... } // // we synthesize a new ast.File, shown below, that dot-imports the -// orginal "cooked" package using a special name ("·this·"), so that all +// original "cooked" package using a special name ("·this·"), so that all // references to package members resolve correctly. (References to // unexported names cause an "unexported" error, which we ignore.) // diff --git a/go/analysis/passes/errorsas/errorsas.go b/go/analysis/passes/errorsas/errorsas.go index c411466c28..01abc70017 100644 --- a/go/analysis/passes/errorsas/errorsas.go +++ b/go/analysis/passes/errorsas/errorsas.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// The errorsas package defines an Analyzer that checks that the second arugment to +// The errorsas package defines an Analyzer that checks that the second argument to // errors.As is a pointer to a type implementing error. package errorsas diff --git a/go/analysis/validate.go b/go/analysis/validate.go index 6e6cf4984f..b984ab6c2d 100644 --- a/go/analysis/validate.go +++ b/go/analysis/validate.go @@ -10,7 +10,7 @@ import ( // Checks include: // that the name is a valid identifier; // that analyzer names are unique; -// that the Requires graph is acylic; +// that the Requires graph is acyclic; // that analyzer fact types are unique; // that each fact type is a pointer. func Validate(analyzers []*Analyzer) error {