-
Notifications
You must be signed in to change notification settings - Fork 18.8k
Closed
Labels
Milestone
Description
What version of Go are you using (go version)?
$ go version go version go1.11.1 linux/amd64
goimports from 34b416b.
Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (go env)?
go env Output
$ go env GOARCH="amd64" GOBIN="/home/dcelasun/go/bin" GOCACHE="/home/dcelasun/.cache/go-build" GOEXE="" GOFLAGS="" GOHOSTARCH="amd64" GOHOSTOS="linux" GOOS="linux" GOPATH="/home/dcelasun/go" GOPROXY="" GORACE="" GOROOT="/usr/lib/go" GOTMPDIR="" GOTOOLDIR="/usr/lib/go/pkg/tool/linux_amd64" GCCGO="gccgo" CC="gcc" CXX="g++" CGO_ENABLED="1" GOMOD="" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build196516147=/tmp/go-build -gno-record-gcc-switches"
What did you do?
$ git clone https://github.com/dcelasun/importbug.git $GOPATH/src/github.com/dcelasun/importbug
$ cd $GOPATH/src/github.com/dcelasun/importbug
$ go get -u golang.org/x/tools/cmd/goimports
$ goimports -l -w main.go
$ go buildSee: https://github.com/dcelasun/importbug
What did you expect to see?
Successfully build the program.
What did you see instead?
$ go build
# github.com/dcelasun/importbug
./main.go:8:14: undefined: fbbecause goimports removed the github.com/dcelasun/importbug/go-foobar import.
Reactions are currently unavailable