The internal/types/errors package defines all error codes used by
the type checkers. This is the 1st step of several that factor out
the error codes from go/types and types2; the package is not yet
used.
- The file codes.go is a copy of go/types/errorcodes.go. The
only change is the updated package name (types -> errors).
- The file codes_test.go is a copy of go/types/errorcodes_test.go
with updated package name (types_test -> errors_test) and minor
changes to walkCodes so that it doesn't require the pkgFiles
helper function (the test only parses a single file).
Change-Id: Idb977b1220737b56b330de1d977f698f022daafc
Reviewed-on: https://go-review.googlesource.com/c/go/+/439560
Run-TryBot: Robert Griesemer <gri@google.com>
Auto-Submit: Robert Griesemer <gri@google.com> Reviewed-by: Robert Findley <rfindley@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Robert Griesemer <gri@google.com>