]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: deduplication in the source code generated by mknode
authorYoulin Feng <fengyoulin@live.com>
Wed, 20 Aug 2025 03:48:05 +0000 (11:48 +0800)
committerGopher Robot <gobot@golang.org>
Thu, 21 Aug 2025 18:18:07 +0000 (11:18 -0700)
commitba840c1bf9be0c3b133f2efd638ec6d32dbedaff
treedfe36ab3e448473227da188a8d5aecdc0219634c
parentfa706ea50fd0b9bf36d642d3bb8eeb732caafc7f
cmd/compile: deduplication in the source code generated by mknode

Most types in the ir package don't have hidden children, so having
their doChildrenWithHidden and editChildrenWithHidden methods call
their own doChildren and editChildren methods can save a lot of
duplicate code.

Change-Id: Ib22a29d6a9a32855f3c3191ca2d26dff94ac556b
Reviewed-on: https://go-review.googlesource.com/c/go/+/697476
Reviewed-by: Keith Randall <khr@golang.org>
Auto-Submit: Keith Randall <khr@golang.org>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Keith Randall <khr@google.com>
Reviewed-by: Carlos Amedee <carlos@golang.org>
src/cmd/compile/internal/ir/mknode.go
src/cmd/compile/internal/ir/node_gen.go