mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
go/types, types2: rename Environment to Context
Replace the name Environment with Context, as discussed in #47916. Along the way, fix some stale or inaccurate comments. The Environment type remains temporarily as an alias for Context, to allow the x/tools Trybot to pass until dependency on types.Environment can be removed. Updates #47916 Change-Id: Iffd069ab0e8adebf4207c8f8891468a64d32b7cc Reviewed-on: https://go-review.googlesource.com/c/go/+/353089 Trust: Robert Findley <rfindley@google.com> Run-TryBot: Robert Findley <rfindley@google.com> Reviewed-by: Robert Griesemer <gri@golang.org> TryBot-Result: Go Bot <gobot@golang.org>
This commit is contained in:
parent
b35c668072
commit
99d5d8ab6b
26 changed files with 214 additions and 214 deletions
|
|
@ -34,13 +34,13 @@ func checkFiles(noders []*noder) (posMap, *types2.Package, *types2.Info) {
|
|||
}
|
||||
|
||||
// typechecking
|
||||
env := types2.NewEnvironment()
|
||||
env := types2.NewContext()
|
||||
importer := gcimports{
|
||||
env: env,
|
||||
packages: map[string]*types2.Package{"unsafe": types2.Unsafe},
|
||||
}
|
||||
conf := types2.Config{
|
||||
Environment: env,
|
||||
Context: env,
|
||||
GoVersion: base.Flag.Lang,
|
||||
IgnoreLabels: true, // parser already checked via syntax.CheckBranches mode
|
||||
CompilerErrorMessages: true, // use error strings matching existing compiler errors
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue