aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/compile/internal/ir/node.go
diff options
context:
space:
mode:
authorDan Scales <danscales@google.com>2021-11-18 10:52:35 -0800
committerDan Scales <danscales@google.com>2021-11-19 00:05:59 +0000
commite8cda0a6c925668972ada40602ada08468fa90dc (patch)
treea5aa331212a12003ef5740b787140fd7927dd3fc /src/cmd/compile/internal/ir/node.go
parent2375b6edf376f97d0d8e3978fa3211788bc9b4dd (diff)
downloadgo-e8cda0a6c925668972ada40602ada08468fa90dc.tar.xz
cmd/compile: don't run ComputeAddrTaken on imported generic functions
It causes a crash because of the unexpected XDOT operation. It's not needed, since we will run ComputeAddrTaken() on function instantiations after stenciling. And it's not always correct, since we may not be able to distinguish between a array and a slice, if a type is dependent on a type param. However, we do need to call ComputeAddrTaken on instantiations created during inlining, since that is after the main ComputeAddrTaken pass. Fixes #49659 Change-Id: I0bb610cf11f14e4aa9068f6ca2a012337b069c79 Reviewed-on: https://go-review.googlesource.com/c/go/+/365214 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/cmd/compile/internal/ir/node.go')
-rw-r--r--src/cmd/compile/internal/ir/node.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cmd/compile/internal/ir/node.go b/src/cmd/compile/internal/ir/node.go
index 8784f9ef99..4fdee5010b 100644
--- a/src/cmd/compile/internal/ir/node.go
+++ b/src/cmd/compile/internal/ir/node.go
@@ -584,7 +584,7 @@ func OuterValue(n Node) Node {
for {
switch nn := n; nn.Op() {
case OXDOT:
- base.FatalfAt(n.Pos(), "OXDOT in walk: %v", n)
+ base.FatalfAt(n.Pos(), "OXDOT in OuterValue: %v", n)
case ODOT:
nn := nn.(*SelectorExpr)
n = nn.X