mirror of https://github.com/golang/go.git
go/types: generate initorder.go from types2 source
This CL reduces the amount of code that needs to be maintained manually by about 320 LOC. Change-Id: Ib797e86dd4abd3a9fe614787103f0e5cebd5e4ae Reviewed-on: https://go-review.googlesource.com/c/go/+/565838 Reviewed-by: Robert Griesemer <gri@google.com> Reviewed-by: Robert Findley <rfindley@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Auto-Submit: Robert Griesemer <gri@google.com>
This commit is contained in:
parent
ff8a2c0ad9
commit
629a6f5ae0
|
|
@ -314,11 +314,11 @@ func (a nodeQueue) Less(i, j int) bool {
|
|||
return x.ndeps < y.ndeps || x.ndeps == y.ndeps && x.obj.order() < y.obj.order()
|
||||
}
|
||||
|
||||
func (a *nodeQueue) Push(x interface{}) {
|
||||
func (a *nodeQueue) Push(x any) {
|
||||
panic("unreachable")
|
||||
}
|
||||
|
||||
func (a *nodeQueue) Pop() interface{} {
|
||||
func (a *nodeQueue) Pop() any {
|
||||
n := len(*a)
|
||||
x := (*a)[n-1]
|
||||
x.index = -1 // for safety
|
||||
|
|
|
|||
|
|
@ -127,6 +127,7 @@ var filemap = map[string]action{
|
|||
"gcsizes.go": func(f *ast.File) { renameIdents(f, "IsSyncAtomicAlign64->_IsSyncAtomicAlign64") },
|
||||
"hilbert_test.go": func(f *ast.File) { renameImportPath(f, `"cmd/compile/internal/types2"->"go/types"`) },
|
||||
"infer.go": func(f *ast.File) { fixTokenPos(f); fixInferSig(f) },
|
||||
"initorder.go": nil,
|
||||
// "initorder.go": fixErrErrorfCall, // disabled for now due to unresolved error_ use implications for gopls
|
||||
"instantiate.go": func(f *ast.File) { fixTokenPos(f); fixCheckErrorfCall(f) },
|
||||
"instantiate_test.go": func(f *ast.File) { renameImportPath(f, `"cmd/compile/internal/types2"->"go/types"`) },
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
// Code generated by "go test -run=Generate -write=all"; DO NOT EDIT.
|
||||
|
||||
// Copyright 2014 The Go Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
|
|
|||
Loading…
Reference in New Issue