1
0
mirror of https://github.com/golang/go synced 2024-11-13 20:40:31 -07:00
go/src/cmd
Daniel Martí bef0055a0a cmd/vet: check that C receivers are cgo imports
Otherwise, vet might have false positives when "C" is a variable and
we're just using a method on it. Or when an import was renamed to "C".

Add test files for both of these cases.

Fixes #20655.

Change-Id: I55fb93119444a67fcf7891ad92653678cbd4670e
Reviewed-on: https://go-review.googlesource.com/45551
Run-TryBot: Daniel Martí <mvdan@mvdan.cc>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
Reviewed-by: Rob Pike <r@golang.org>
2017-08-09 02:23:51 +00:00
..
addr2line
api api: promote next to go1.9 2017-06-14 21:07:10 +00:00
asm cmd/internal/obj/arm: check illegal base registers in ARM instructions 2017-06-30 19:09:44 +00:00
cgo cmd/cgo: document that structs and arrays don't work with //export 2017-08-08 04:39:05 +00:00
compile cmd/compile: use right shifts to eliminate bounds checks 2017-08-09 00:21:25 +00:00
cover cmd/cover: take default value of total only once. 2017-06-02 17:59:12 +00:00
dist cmd/dist: skip moved GOROOT on Go's Windows builders when not sharding tests 2017-07-27 05:04:28 +00:00
doc cmd/doc: print Go syntax when printing struct.field docs 2017-07-06 21:57:52 +00:00
fix
go cmd/go: show examples with empty output in go test -list 2017-08-02 14:30:08 +00:00
gofmt
internal cmd/compile: set/unset base register for better assembly print 2017-08-02 12:24:02 +00:00
link cmd/link: use full link, not compile, to test for -no-?pie 2017-07-24 17:50:57 +00:00
nm
objdump cmd/internal/objabi: fix the bug of shrinking SymType down to a uint8 2017-05-16 12:26:10 +00:00
pack
pprof cmd/pprof: restore printing descriptive errors from net/http/pprof endpoints 2017-06-15 02:14:24 +00:00
trace
vendor Revert "cmd/vendor/github.com/google/pprof: refresh from upstream" 2017-06-20 19:46:11 +00:00
vet cmd/vet: check that C receivers are cgo imports 2017-08-09 02:23:51 +00:00