go.tools/go/*: fix breakage caused by removal of types.NewPackage parameter.
(This fixes the build, but one test is failing.) TBR=gri R=gri CC=golang-codereviews https://golang.org/cl/66730043
This commit is contained in:
parent
01263f0a00
commit
49eaa56ed1
|
|
@ -157,7 +157,7 @@ func (p *parser) getPkg(pkgpath, name string) *types.Package {
|
|||
}
|
||||
pkg := p.imports[pkgpath]
|
||||
if pkg == nil && name != "" {
|
||||
pkg = types.NewPackage(pkgpath, name, types.NewScope(nil))
|
||||
pkg = types.NewPackage(pkgpath, name)
|
||||
p.imports[pkgpath] = pkg
|
||||
}
|
||||
return pkg
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ func (p *importer) pkg() *types.Package {
|
|||
// if the package was imported before, use that one; otherwise create a new one
|
||||
pkg := p.imports[path]
|
||||
if pkg == nil {
|
||||
pkg = types.NewPackage(path, name, types.NewScope(nil))
|
||||
pkg = types.NewPackage(path, name)
|
||||
p.imports[path] = pkg
|
||||
}
|
||||
p.pkgList = append(p.pkgList, pkg)
|
||||
|
|
|
|||
Loading…
Reference in New Issue