tools/go
Alan Donovan 02f1928320 go/loader: ignore (*build.Package).Goroot flag when handling "unsafe"
For the default build.Context, the Package.Goroot flag indicates when a
package was loaded from the standard library.  Until now, the loader
used it to enable the typechecker's intrinsics for the "unsafe" package.
This seemed like a good check, but it is troublesome for clients that
use a nonstandard build.Context.  For example, if a client defines
nonstandard Context hooks that load all packages, whether standard or
user-defined, from a flat sstable, there is no way for those hooks to
indicate which packages should have this flag set and which not.  As a
result the contents of the "unsafe" package directory are treated as Go
source code when they are merely documentation.

Change-Id: Iea0a7cc9877507d73606391293971a28279c4e4b
Reviewed-on: https://go-review.googlesource.com/19188
Reviewed-by: Robert Griesemer <gri@golang.org>
2016-02-05 00:45:20 +00:00
..
ast/astutil go/ast/astutil: set Pos for import name 2015-05-19 23:10:16 +00:00
buildutil x/tools: fix build 2016-01-21 22:29:25 +00:00
callgraph tools: switch to standard go/types at tip 2016-01-06 22:15:26 +00:00
exact tools: add import comments. 2014-12-09 22:42:16 +00:00
gccgoimporter x/tools: disable tests not supported on Android 2015-08-06 00:36:03 +00:00
gcimporter go/types: change {Type,Object,Selection}String to accept a Qualifier function 2015-06-30 19:00:00 +00:00
gcimporter15 go/gcimporter15: fix build 2016-01-27 07:08:15 +00:00
importer go/importer: in TestImportStdLib, skip 2 packages that use vendoring 2015-12-28 21:28:10 +00:00
loader go/loader: ignore (*build.Package).Goroot flag when handling "unsafe" 2016-02-05 00:45:20 +00:00
pointer all: skip slow tests in short mode 2016-01-28 00:14:01 +00:00
ssa all: fix plan9 failures 2016-01-28 00:31:03 +00:00
types go/types: fix a comment of Named.Obj 2016-01-16 17:31:34 +00:00
vcs go/vcs: drop support for Google Code Project Hosting 2016-01-27 00:23:28 +00:00