]> Cypherpunks repositories - gostls13.git/commit
go/types, types2: mechanically replace read accesses to operand.typ_
authorMark Freeman <mark@golang.org>
Mon, 2 Feb 2026 19:00:43 +0000 (14:00 -0500)
committerGopher Robot <gobot@golang.org>
Thu, 5 Feb 2026 22:24:12 +0000 (14:24 -0800)
commitcfe0f5557163ae64c19bccf51e2c98fa0fc76430
treec762ae9a2bf3b10ba36db090446e5bc02cd49a57
parentfd146ff3b315c54e271a886d7451d0abd89f2cad
go/types, types2: mechanically replace read accesses to operand.typ_

This provides a hook to enforce that operand.typ is only observed where
operand.mode is not invalid.

For #76110

Change-Id: I915f3ac09dc10bfe3f9f688d6190ad58e195ddcb
Reviewed-on: https://go-review.googlesource.com/c/go/+/741220
Auto-Submit: Mark Freeman <markfreeman@google.com>
Reviewed-by: Robert Griesemer <gri@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
28 files changed:
src/cmd/compile/internal/types2/assignments.go
src/cmd/compile/internal/types2/builtins.go
src/cmd/compile/internal/types2/call.go
src/cmd/compile/internal/types2/const.go
src/cmd/compile/internal/types2/conversions.go
src/cmd/compile/internal/types2/expr.go
src/cmd/compile/internal/types2/index.go
src/cmd/compile/internal/types2/infer.go
src/cmd/compile/internal/types2/literals.go
src/cmd/compile/internal/types2/operand.go
src/cmd/compile/internal/types2/range.go
src/cmd/compile/internal/types2/recording.go
src/cmd/compile/internal/types2/stmt.go
src/cmd/compile/internal/types2/typexpr.go
src/go/types/assignments.go
src/go/types/builtins.go
src/go/types/call.go
src/go/types/const.go
src/go/types/conversions.go
src/go/types/expr.go
src/go/types/index.go
src/go/types/infer.go
src/go/types/literals.go
src/go/types/operand.go
src/go/types/range.go
src/go/types/recording.go
src/go/types/stmt.go
src/go/types/typexpr.go