aboutsummaryrefslogtreecommitdiff
path: root/src/syscall/exec_linux.go
diff options
context:
space:
mode:
authorRob Findley <rfindley@google.com>2021-04-26 19:23:05 -0400
committerRobert Findley <rfindley@google.com>2021-04-27 02:20:29 +0000
commit15105dd4b56610e18fa4b5744c7deca069085bc5 (patch)
tree97c5f4439724876e8f1c97b2faf70f101fefe8d9 /src/syscall/exec_linux.go
parent40254ec0db6d02118df141dbe7fcb6a95aec6560 (diff)
downloadgo-15105dd4b56610e18fa4b5744c7deca069085bc5.tar.xz
go/types: walk all imports when determining package name ambiguity
CL 209578 disambiguated paths among imported packages, but as demonstrated in #43119, formatted types may reference packages that are not directly imported. Fix this by recursively walking all imports to determine whether there is any ambiguity in the import graph. This might result in over-qualification of names, but it is straightforward and should eliminate any ambiguity. In general this should be fine, but might introduce risk of infinite recursion in the case of an importer bug, or performance problems for very large import graphs. Mitigate the former by tracking seen packages, and the latter by only walking the import graph once an error has been produced. Fixes #43119 Change-Id: If874f050ad0e808db8e354c2ffc88bc6d64fd277 Reviewed-on: https://go-review.googlesource.com/c/go/+/313035 Trust: Robert Findley <rfindley@google.com> Trust: Robert Griesemer <gri@golang.org> Run-TryBot: Robert Findley <rfindley@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Robert Griesemer <gri@golang.org>
Diffstat (limited to 'src/syscall/exec_linux.go')
0 files changed, 0 insertions, 0 deletions