diff options
| author | Jay Conrod <jayconrod@google.com> | 2019-05-10 11:49:08 -0400 |
|---|---|---|
| committer | Jay Conrod <jayconrod@google.com> | 2019-05-10 16:28:38 +0000 |
| commit | 3b8c804164e26bdec6ca94a5ab1b5c35fa119e5e (patch) | |
| tree | 01d27b1bfbcdc6b85c3efc5a238adcf86b266507 /src/testing/testing.go | |
| parent | ef4666eccedd457b33baa5b7d4bff95680e60741 (diff) | |
| download | go-3b8c804164e26bdec6ca94a5ab1b5c35fa119e5e.tar.xz | |
cmd/go: force -coverpkg main packages to be built as libraries
This fixes TestScript/cover_pkgall_multiple_mains, which started
failing after CL 174657.
When compiling main packages with coverage instrumentation
(e.g., for -coverpkg all), we now pass -p with the full import path
instead of '-p main'. This avoids link errors
'duplicate symbol main.main (types 1 and 1)'.
Fixes #31946
Change-Id: Id147527b1dbdc14bb33ac133c30d50c250b4365c
Reviewed-on: https://go-review.googlesource.com/c/go/+/176558
Run-TryBot: Jay Conrod <jayconrod@google.com>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/testing/testing.go')
0 files changed, 0 insertions, 0 deletions
