It's okay to have GOROOT=$HOME/go, GOPATH=$HOME.
That's what I have.
It's just not okay to hack in Go under $GOPATH/src.
Change-Id: I6ae69aceb43970bbdc9631ab090689a153954087
Reviewed-on: https://go-review.googlesource.com/45651
Reviewed-by: Steve Francia <spf@golang.org>
Disable health checker - it only causes trouble if we're running on one
instance. We'd rather see "starting up" than to have nothing served and
the instance killed when it doesn't come up ready in time.
Change-Id: I3396c626f840d606e0fb4a5ec4c0493195fd015f
Reviewed-on: https://go-review.googlesource.com/45654
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This error was previously ignored. This caused a silent failure when the
meta URL wasn't accessible.
Change-Id: I4020897ac15fec7b60a46277d81a99a6b6447a7d
Reviewed-on: https://go-review.googlesource.com/45655
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Provide more context when you run `stress -h` besides just the flags.
Change-Id: I9dbe7ba2b7178dd7a542d8c4c29bf79999a38234
Reviewed-on: https://go-review.googlesource.com/44810
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Adds an Imports field to packageInfo with the imports used by sibling
files, and uses it preferentially if it matches a missing import.
Example: if foo/foo.go imports "local/log", it's a reasonable assumption
that foo/bar.go will also want "local/log" instead of "log".
Change-Id: Ifb504ed5e00ff18459f19d8598cc2c94099ae563
Reviewed-on: https://go-review.googlesource.com/43454
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This time, chose a package that's not changed across several builds.
Follow-up on https://go-review.googlesource.com/45151.
Change-Id: I0b487a45f8b12179b3aa495d852c0b7caa44c921
Reviewed-on: https://go-review.googlesource.com/45154
Run-TryBot: Robert Griesemer <gri@golang.org>
Reviewed-by: Alan Donovan <adonovan@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This is now allowed in go1.8.
Fixesgolang/go#19646.
Change-Id: Iece4fd2a881144bdbe841e0a26ba4348d6b8828e
Reviewed-on: https://go-review.googlesource.com/38452
Reviewed-by: Alan Donovan <adonovan@google.com>
Run-TryBot: Alan Donovan <adonovan@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
DeleteNamedImport assumes the import declaration is in the form of:
import (
"foo"
)
If an import path is deleted there might be a blank line-sized hole:
import (
)
It'll merge the black hole with the last line to change it to:
import (
)
However the import declaration might be in the following form as well:
import (
"foo")
Whic means after deleting the import path, it changes to:
import (
)
In this case it still tries to merge the line with a non existing line,
causing token.File.MergeLine to panic.
We fix the issue by checking that the import path line is not the last
line to avoid panicing.
Fixesgolang/go#20229
Change-Id: I37537a4eaa83d14db59a2926d7bb14c27167a2e4
Reviewed-on: https://go-review.googlesource.com/44372
Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
In the go/doc, the same map as "predeclared" is defined.
Instead of the "predeclared" map use the "IsPredeclared" function
which is an accessor for the go/doc map.
Deleted unnecessary "predeclared".
Fixesgolang/go#20357
Change-Id: I7fdf42cfeb4440fb490be9380f39035be88f9a5a
Reviewed-on: https://go-review.googlesource.com/43473
Reviewed-by: Kevin Burke <kev@inburke.com>
The link of the function declaration part is unnecessary because it points to the same place.
Removed the link of the function declaration part.
"IdentMode" has been removed since it is no longer used.
Fixesgolang/go#20269
Change-Id: I6399899947e46dc84c5432c1d645f6d96b7db4f6
Reviewed-on: https://go-review.googlesource.com/42892
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This mostly reverts commit 1c59bc354d
(CL 43350) which had fixed Go tip but broken Go 1.7 and Go 1.8
builders.
Change-Id: I4e7bdfafde74c9e730bb870b9db05b663b4f56a3
Reviewed-on: https://go-review.googlesource.com/43391
Reviewed-by: Alan Donovan <adonovan@google.com>
http://golang.org/cl/41476 added the internal/cpu package
to unify cpu feature flag detection in the standard library.
Add a replacement for the assembler function internal/cpu.cpuid
that simulates a x86 cpu with no feature detection capabilities.
Remove bytes.init and strings.init from the external function list
because they do not depend on assembler functions anymore.
Remove hash/crc32.haveSSE42 and math.hasSSE4 because they
have been removed from the go standard library.
Change-Id: Icab6ed3cb13eb14b28d23f2b9c5ae94688f2dc95
Reviewed-on: https://go-review.googlesource.com/43350
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Updates golang/go#19906
Change-Id: If13c828541cdb3937e5e970dd8add7615d36d866
Reviewed-on: https://go-review.googlesource.com/40171
Reviewed-by: David R. Jenni <david.r.jenni@gmail.com>
Reviewed-by: Robert Griesemer <gri@golang.org>
Reviewed-by: Alan Donovan <adonovan@google.com>
The GOROOT of whatever tool build toolstash is irrelevant. We want
the goroot of the "go" command we're testing.
Change-Id: Ie7e11c74cb445ea694d88c743dbc239a55d47864
Reviewed-on: https://go-review.googlesource.com/43033
Run-TryBot: Keith Randall <khr@golang.org>
Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
The "go" command is a random "go" in the environment, not
necessarily the one under test. Use the go command in the
goroot we're testing.
This CL removes the need to add $GOROOT/bin to your path
before running compilebench.
Change-Id: Ieb7f441f8287105e13446006e73b760d80e51e03
Reviewed-on: https://go-review.googlesource.com/42932
Run-TryBot: Keith Randall <khr@golang.org>
Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
importPath and srcDir are both of string type.
Change-Id: Ia5230bd19ea83bc210cb0b1a50046e4e0ef2accb
Reviewed-on: https://go-review.googlesource.com/42890
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
go-mode does not use go-mode-load now.
Need to use go-mode-autoloads instead.
Change-Id: I3ee2113b41972a1f700d604ea7a6c2d5b59da8bb
Reviewed-on: https://go-review.googlesource.com/42193
Reviewed-by: Alan Donovan <adonovan@google.com>
Manually apply same change as CL 41822 did for cmd/go/internal/get,
but for golang.org/x/tools/go/vcs, to help keep them in sync.
Updates golang/go#18660.
Helps golang/go#11490.
Change-Id: I6c7759c073583dea771bc438b70f8c2eb7b5ebfb
Reviewed-on: https://go-review.googlesource.com/42017
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This reverts commit 3aa1caa08a.
Reason for revert: benchstat is preferred to benchcmp
Change-Id: I9772eb342fb631a68511986d832bb1444766afdc
Reviewed-on: https://go-review.googlesource.com/42027
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This package has been moved since then.
Change-Id: Ibf0044cf4fcef47ae15301c2880ff129a8829516
Reviewed-on: https://go-review.googlesource.com/41856
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
A go/build change in Go 1.9 (CL 33158) allowed for a better expected
error message for "nonexistingpkg" case. CL 37768 did that. However,
that shouldn't be done for Go 1.8 and older, since they don't have
the corresponding go/build change.
So, if the version is Go 1.8 or older, allow matching those previous
expected outputs (before CL 37768) for "nonexistingpkg" case.
Move test cases for TestCLI from a package-level variable into TestCLI
itself. This is more readable, and isGo19's value is ready in time.
Fixesgolang/go#20122.
Change-Id: I5e80600a75176d9e54ffebb7730849e381568316
Reviewed-on: https://go-review.googlesource.com/41810
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Backport of CL 41619.
Generated by copying bimport.go and reverting
the chunk containing the "This file is a copy"
comment near the top.
Fixesgolang/go#20121
Change-Id: If24c97d01a550318ab919c37cd0c4a8f34d776c7
Reviewed-on: https://go-review.googlesource.com/41756
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Sometimes, as with CL 41493, or when investigating
a reported issue, there's a package of interest
that is not part of the standard compilebench suite.
Add a -pkg flag to allow easy access to the compilebench
set of goodies (allocs, object file stats) without
having to edit and reinstall compilebench itself,
which is what I have been doing.
Change-Id: Id6ca6356cae062208f8686c0cb597ed45fc861c0
Reviewed-on: https://go-review.googlesource.com/41627
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Insert line numbers via a ::before pseudo-element so you can't select
them when you copy text. See the code comment for more information.
Fixesgolang/go#20077.
Change-Id: I24a5b17786a52c8107b4f830e824526ba03bc38d
Reviewed-on: https://go-review.googlesource.com/41418
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
(specifically: strings.Count, testing.callerEntry)
The interpreter tests were very useful for finding bugs during
development of go/ssa but now seem to be all cost and no benefit.
It may be time to delete this package.
Change-Id: I22348be9fb37bb0fd0c572c3e6f57e70fc069e02
Reviewed-on: https://go-review.googlesource.com/40871
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
godoc once again adds anchors for variable and constant
declarations. Individual declarations and lists of declarations are
both covered.
Fixesgolang/go#19894
Change-Id: If5f8f0c3429774f33535e2e654685ba5d71937f1
Reviewed-on: https://go-review.googlesource.com/40300
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
And avoid assumptions about the contents of the standard hash/fnv
package.
Change-Id: I10cc95ac6e3b482da5b027d68ff218d08f425e89
Reviewed-on: https://go-review.googlesource.com/40870
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>