1
0
mirror of https://github.com/golang/go synced 2024-11-18 12:54:44 -07:00
go/cmd
Alan Donovan 3d82e7e94a go.tools/ssa: fix crash in SSA builder when using GCImporter to satisfy imports (ssadump -build=G).
Packages were not being created for all types.Packages,
specifically, indirectly imported packages were missing.
(*Program).CreatePackages now iterates over the type-checker's
package map too.

Also: removed all concurrency from importer.  I think it was
incorrect (and hard to fix).

Also: change LoadInitialPackages so that all named packages
are loaded from source.  This happens regardless of whether
GCImporter is used to satisfy imports.

Details:
- importer.Config.SourceImports flag determines whether to
  load all packages from *.go source.
  (Before, this was indicated by Config.Build != nil.)
- importer.Config.Build field effectively defaults to
  &go/build.Default.  A zero importer.Config is now usable.
- importer.Importer.Config field is now exported.
- LoadPackage renamed to ImportPackage since the resulting
  packages may come from GCImporter (and be incomplete).
- doImport and ImportPackage fused.

Fixes golang/go#7028

R=gri, axwalk
CC=golang-codereviews
https://golang.org/cl/48770043
2014-01-09 14:11:54 -05:00
..
cover go.tools/cover: split parsing code out from cmd/cover 2013-12-03 20:55:21 -08:00
godoc godoc: add ability to change or disable the display of search results. 2014-01-06 09:51:01 -05:00
goimports go.tools/cmd/goimports: Fixed url 2014-01-02 11:02:13 -08:00
gotype cmd/gotype: add -gccgo flag 2014-01-08 15:25:17 -08:00
html2article go.tools/cmd/html2article: move command from go.blog repository 2013-09-27 10:40:53 +10:00
oracle go.tools/oracle: implements: now shows whole-program implements relation for selected type. 2013-12-13 18:00:55 -05:00
ssadump go.tools/ssa: fix crash in SSA builder when using GCImporter to satisfy imports (ssadump -build=G). 2014-01-09 14:11:54 -05:00
vet go.tools/cmd/vet: improve error message for build tag problems 2013-12-18 16:06:56 -08:00