mirror of
https://github.com/golang/go
synced 2024-11-22 14:44:50 -07:00
exp/types: permit importing packages without available source.
R=gri, iant CC=golang-dev https://golang.org/cl/6586051
This commit is contained in:
parent
0b448bdef7
commit
ff2f851af1
@ -42,7 +42,8 @@ func FindPkg(path, srcDir string) (filename, id string) {
|
||||
switch {
|
||||
default:
|
||||
// "x" -> "$GOPATH/pkg/$GOOS_$GOARCH/x.ext", "x"
|
||||
bp, _ := build.Import(path, srcDir, build.FindOnly)
|
||||
// Don't require the source files to be present.
|
||||
bp, _ := build.Import(path, srcDir, build.FindOnly|build.AllowBinary)
|
||||
if bp.PkgObj == "" {
|
||||
return
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user