diff options
| author | Austin Clements <austin@google.com> | 2024-04-01 15:39:41 -0400 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2024-04-02 16:25:18 +0000 |
| commit | 94dba61276f26c01b7d3d1a4abb195bdcc596bfd (patch) | |
| tree | 1d1bcc6e167f1889771d3bfbfd01bec53d36e752 /src/internal/reflectlite | |
| parent | cb6d15a747ee7875504fdb4fc28c64c67c5f8d82 (diff) | |
| download | go-94dba61276f26c01b7d3d1a4abb195bdcc596bfd.tar.xz | |
internal/abi: clean up type of Kind and Type.Kind_
Currently, Type.Kind_ is a uint8, Kind is a uint, and some of the
abi.Kind consts are not of type Kind. Clean this all up by making Kind
a uint8, then making Type.Kind a Kind, and finally making all Kind
consts actually have type Kind. This has some ripple effect, but I
think all of the changes are improvements.
Change-Id: If39be74699c2cdb52bf0ad7092d392bc8fb68d15
Reviewed-on: https://go-review.googlesource.com/c/go/+/575579
Auto-Submit: Austin Clements <austin@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
Reviewed-by: Keith Randall <khr@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Diffstat (limited to 'src/internal/reflectlite')
| -rw-r--r-- | src/internal/reflectlite/type.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/internal/reflectlite/type.go b/src/internal/reflectlite/type.go index e585d24f53..8c47a265b8 100644 --- a/src/internal/reflectlite/type.go +++ b/src/internal/reflectlite/type.go @@ -661,5 +661,5 @@ func toType(t *abi.Type) Type { // ifaceIndir reports whether t is stored indirectly in an interface value. func ifaceIndir(t *abi.Type) bool { - return t.Kind_&abi.KindDirectIface == 0 + return abi.Kind(t.Kind_)&abi.KindDirectIface == 0 } |
