aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/panic.go
diff options
context:
space:
mode:
authorDan Scales <danscales@google.com>2021-10-18 18:11:48 -0700
committerDan Scales <danscales@google.com>2021-10-26 20:08:41 +0000
commitb54bdd281e62a4658ea4edb5e0a6139006938c9a (patch)
tree6df6aac4c21491e7a3cf036b6d314a24ab38acf5 /src/runtime/panic.go
parent1dc77a38d293763b9de50110dd72edd755ce72b7 (diff)
downloadgo-b54bdd281e62a4658ea4edb5e0a6139006938c9a.tar.xz
cmd/compile: clean up the switch statements in (*genInst).node()
There were two main outer switch statements in node() that can just be combined. Also, for simplicity, changed an IsCmp() conditional into just another case in the switch statement. Also, the inner OCALL switch statement had a bunch of fairly duplicate cases. Combined the cases that all had no special semantics, into a single default case calling transformCall(). In the OCALL case in dictPass(), got rid of a check for OFUNCINST (which will always have been removed by this point). Also, eliminated an assert that could cause unneded failures. transformCall() should always be called if the node op is still OCALL, so no need to assert on the ops of call.X. Added an extra test in issue47078.go, to explicitly check for case where the X argument of a call is a DOTTYPE. Change-Id: Ifb3f812ce12820a4ce08afe2887f00f7fc00cd2f Reviewed-on: https://go-review.googlesource.com/c/go/+/358596 Trust: Dan Scales <danscales@google.com> Run-TryBot: Dan Scales <danscales@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Keith Randall <khr@golang.org>
Diffstat (limited to 'src/runtime/panic.go')
0 files changed, 0 insertions, 0 deletions