mirror of
https://github.com/golang/go
synced 2024-11-26 05:07:59 -07:00
[dev.typeparams] cmd/compile: move def of comparable to end of predeclared slices
This avoids changing the export ABI. Change-Id: I58950c1f4c21859d91d66d352b88e8c0972b5b8c Reviewed-on: https://go-review.googlesource.com/c/go/+/333164 Trust: Dan Scales <danscales@google.com> Reviewed-by: Robert Griesemer <gri@golang.org>
This commit is contained in:
parent
c65ca97a45
commit
85267f402c
@ -101,8 +101,6 @@ var predeclared = []types2.Type{
|
||||
|
||||
// error
|
||||
types2.Universe.Lookup("error").Type(),
|
||||
// comparable
|
||||
types2.Universe.Lookup("comparable").Type(),
|
||||
|
||||
// untyped types
|
||||
types2.Typ[types2.UntypedBool],
|
||||
@ -121,6 +119,9 @@ var predeclared = []types2.Type{
|
||||
|
||||
// used internally by gc; never used by this package or in .a files
|
||||
anyType{},
|
||||
|
||||
// comparable
|
||||
types2.Universe.Lookup("comparable").Type(),
|
||||
}
|
||||
|
||||
type anyType struct{}
|
||||
|
@ -78,8 +78,6 @@ func predeclared() []*types.Type {
|
||||
|
||||
// error
|
||||
types.ErrorType,
|
||||
// comparable
|
||||
types.ComparableType,
|
||||
|
||||
// untyped types
|
||||
types.UntypedBool,
|
||||
@ -98,6 +96,9 @@ func predeclared() []*types.Type {
|
||||
|
||||
// any type, for builtin export data
|
||||
types.Types[types.TANY],
|
||||
|
||||
// comparable
|
||||
types.ComparableType,
|
||||
}
|
||||
}
|
||||
return predecl
|
||||
|
@ -104,8 +104,6 @@ var predeclared = []types.Type{
|
||||
|
||||
// error
|
||||
types.Universe.Lookup("error").Type(),
|
||||
// comparable
|
||||
types.Universe.Lookup("comparable").Type(),
|
||||
|
||||
// untyped types
|
||||
types.Typ[types.UntypedBool],
|
||||
@ -124,6 +122,9 @@ var predeclared = []types.Type{
|
||||
|
||||
// used internally by gc; never used by this package or in .a files
|
||||
anyType{},
|
||||
|
||||
// comparable
|
||||
types.Universe.Lookup("comparable").Type(),
|
||||
}
|
||||
|
||||
type anyType struct{}
|
||||
|
Loading…
Reference in New Issue
Block a user