summaryrefslogtreecommitdiff
path: root/src/go
Commit message (Collapse)AuthorAgeFilesLines
...
* cmd/compile/internal/gc: enable new parser by defaultMatthew Dempsky2016-10-251-3/+1
| | | | | | | | Change-Id: I3c784986755cfbbe1b8eb8da4d64227bd109a3b0 Reviewed-on: https://go-review.googlesource.com/27203 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Robert Griesemer <gri@golang.org>
* go/types: match cmd/compile's alignment for complex64Matthew Dempsky2016-10-251-0/+4
| | | | | | | | | | Fixes #17584. Change-Id: I3af31cc1f2e9c906f3b73e77f3b092624ba78fbe Reviewed-on: https://go-review.googlesource.com/31939 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Robert Griesemer <gri@golang.org>
* cmd/compile: implement package-level aliases (no export yet)Robert Griesemer2016-10-251-0/+1
| | | | | | | | | | | Requires -newparser=1. For #17487. For #16339. Change-Id: I156fb0c0f8a97e8c72dbbfbd7fe821efee12b957 Reviewed-on: https://go-review.googlesource.com/31597 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/build: allow % in ${SRCDIR} expansion for JenkinsRuss Cox2016-10-242-1/+3
| | | | | | | | | | Fixes #16959. Change-Id: Ibbb28fdf26c53788a0edb3e3ea54ec030fa2a8cf Reviewed-on: https://go-review.googlesource.com/31611 Run-TryBot: Russ Cox <rsc@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
* go/build: do not record go:binary-only-package if build tags not satisfiedRuss Cox2016-10-241-4/+7
| | | | | | | | | | This is the documented (and now implemented) behavior. Fixes #16841. Change-Id: Ic75adc5ba18303ed9578e04284f32933f905d6a3 Reviewed-on: https://go-review.googlesource.com/31577 Reviewed-by: Quentin Smith <quentin@golang.org>
* go/build: reserve GOOS=zos for IBM z/OSMichael Munday2016-10-201-1/+1
| | | | | | | | | | | Closes #17528. Change-Id: I2ba55ad4e41077808f882ed67a0549f0a00e25d0 Reviewed-on: https://go-review.googlesource.com/31596 Run-TryBot: Michael Munday <munday@ca.ibm.com> Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Minux Ma <minux@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
* net/http/httptrace: add ClientTrace.TLSHandshakeStart & TLSHandshakeDoneEdward Muller2016-10-191-1/+1
| | | | | | | | | | Fixes #16965 Change-Id: I3638fe280a5b1063ff589e6e1ff8a97c74b77c66 Reviewed-on: https://go-review.googlesource.com/30359 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
* crypto/tls: support ChaCha20-Poly1305.Adam Langley2016-10-171-0/+2
| | | | | | | | | | | | | This change adds support for the ChaCha20-Poly1305 AEAD to crypto/tls, as specified in https://tools.ietf.org/html/rfc7905. Fixes #15499. Change-Id: Iaa689be90e03f208c40b574eca399e56f3c7ecf1 Reviewed-on: https://go-review.googlesource.com/30957 Run-TryBot: Adam Langley <agl@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
* cmd/dist, go/build: make CGO_ENABLED during make.bash stickyRuss Cox2016-10-171-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | Per discussion on #12808, it's a bit odd that if you do CGO_ENABLED=0 ./make.bash then you get a toolchain that still tries to use cgo. So make the CGO_ENABLED setting propagate into the resulting toolchain as the default setting for that environment variable, like we do with other variables like CC and GOROOT. No reasonable way to test automatically, but I did test by hand that after the above command, 'go env' shows CGO_ENABLED=0; before it showed CGO_ENABLED=1. Fixes #12808. Change-Id: I26a2fa6cc00e73bde8af7469270b27293392ed71 Reviewed-on: https://go-review.googlesource.com/31141 Run-TryBot: Russ Cox <rsc@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
* go/internal/gcimporter: set Pos attribute of decoded types.ObjectsAlan Donovan2016-10-132-19/+61
| | | | | | | | | This change is a copy of CL 22788 in x/tools. It has no observable effect yet, but brings the two packages in synch. Change-Id: I266c77547cb46deb69b1a36e1674dfebc430e3a5 Reviewed-on: https://go-review.googlesource.com/22936 Reviewed-by: Russ Cox <rsc@golang.org>
* crypto/tls: support X25519.Adam Langley2016-10-121-0/+1
| | | | | | | | | | | | | | X25519 (RFC 7748) is now commonly used for key agreement in TLS connections, as specified in https://tools.ietf.org/html/draft-ietf-tls-curve25519-01. This change adds support for that in crypto/tls, but does not enabled it by default so that there's less test noise. A future change will enable it by default and will update all the test data at the same time. Change-Id: I91802ecd776d73aae5c65bcb653d12e23c413ed4 Reviewed-on: https://go-review.googlesource.com/30824 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
* go/types: expose Default function, which converts untyped T to TAlan Donovan2016-10-125-9/+9
| | | | | | Change-Id: Ibcf5e0ba694b280744a00c2c6fda300f0a653455 Reviewed-on: https://go-review.googlesource.com/30715 Reviewed-by: Robert Griesemer <gri@golang.org>
* go/importer: better error messages when export data is not foundRobert Griesemer2016-10-061-4/+6
| | | | | | | | Fixes #17281. Change-Id: I4e639998dbe3baa98879f1becc37d7c4d19351e7 Reviewed-on: https://go-review.googlesource.com/30473 Reviewed-by: Alan Donovan <adonovan@google.com>
* go/doc: hide methods on locally-declared predeclared typesLarz Conwell2016-10-065-5/+69
| | | | | | | | | | | | | | Currently if you declare a type overwriting a predeclared type and export methods on it they will be exposed in godoc, even though the type itself is not exported. This corrects that by making all methods on these types hidden, since that's the expected output. Fixes #9860 Change-Id: I14037bdcef1b4bbefcf299a143bac8bf363718e0 Reviewed-on: https://go-review.googlesource.com/20610 Reviewed-by: Russ Cox <rsc@golang.org>
* cmd/go: note when some Go files were ignored on no-Go-files errorsJaana Burcu Dogan2016-10-063-3/+22
| | | | | | | | | | | | | | It is pretty confusing when there are Go files ignored for mismatching build tags and similar and we output "no buildable Go files" without giving any other information about some Go files have been ignored. Fixes #17008. Change-Id: I1766ee86a9a7a72f6694deae3f73b47bfc9d0be5 Reviewed-on: https://go-review.googlesource.com/29113 Run-TryBot: Jaana Burcu Dogan <jbd@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
* go/types: minimal support for alias declarations: don't crashRobert Griesemer2016-10-043-0/+14
| | | | | | | | For #16339 Change-Id: I8927f40e0fd166795f41c784ad92449743f73af5 Reviewed-on: https://go-review.googlesource.com/30213 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/printer: support for printing alias declarationsRobert Griesemer2016-10-043-7/+151
| | | | | | | | For #16339. Change-Id: Ie2e3338b87e84f45cda0868213bbcd2dae9ab6e3 Reviewed-on: https://go-review.googlesource.com/30212 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/ast, go/parser: parse alias declarationsRobert Griesemer2016-10-045-32/+97
| | | | | | | | | | | | For now, we also accept "type p = p.T" (using = instead of =>, for type aliases only), so we can experiment with an approach that only uses type aliases. This concession is implemened in the parser. For #16339 Change-Id: I88b5522a8b6cfc2e97ca146ede8b32af340220f8 Reviewed-on: https://go-review.googlesource.com/30211 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/scanner, go/token: recognize => (ALIAS) tokenRobert Griesemer2016-10-043-2/+9
| | | | | | | | For #16339. Change-Id: I0f83e46f13b5c8801aacf48fc8b690049edbbbff Reviewed-on: https://go-review.googlesource.com/30210 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/types: ignore struct tags when converting structsRobert Griesemer2016-10-044-17/+337
| | | | | | | | | | Implementation of spec change https://golang.org/cl/24190/. For #16085. Change-Id: I17bbbce38d98a169bc64e84983a7ebfe7142f6e9 Reviewed-on: https://go-review.googlesource.com/30190 Reviewed-by: Alan Donovan <adonovan@google.com>
* net: implement network interface API for SolarisMikio Hara2016-10-041-1/+1
| | | | | | | | | Fixes #7177. Change-Id: Iba6063905f4f9c6acef8aba76b55d996f186d835 Reviewed-on: https://go-review.googlesource.com/29892 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Mikio Hara <mikioh.mikioh@gmail.com>
* sort: add Slice, SliceStable, and SliceIsSortedBrad Fitzpatrick2016-10-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | Add helpers for sorting slices. Slice sorts slices: sort.Slice(s, func(i, j int) bool { if s[i].Foo != s[j].Foo { return s[i].Foo < s[j].Foo } return s[i].Bar < s[j].Bar }) SliceStable is the same, but does a stable sort. SliceIsSorted reports whether a slice is already sorted. Fixes #16721 Change-Id: I346530af1c5dee148ea9be85946fe08f23ae53e7 Reviewed-on: https://go-review.googlesource.com/27321 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Russ Cox <rsc@golang.org>
* net/http: update bundled http2, add h2 Transport.IdleConnTimeout testsBrad Fitzpatrick2016-09-301-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | Updates bundled http2 to x/net git rev a333c53 for: http2: add Transport support for IdleConnTimeout https://golang.org/cl/30075 And add tests. The bundled http2 also includes a change adding a Ping method to http2.ClientConn, but that type isn't exposed in the standard library. Nevertheless, the code gets compiled and adds a dependency on "crypto/rand", requiring an update to go/build's dependency test. Because net/http already depends on crypto/tls, which uses crypto/rand, it's not really a new dependency. Fixes #16808 Change-Id: I1ec8666ea74762f27c70a6f30a366a6647f923f7 Reviewed-on: https://go-review.googlesource.com/30078 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
* net/http: add more IDNA2008 tests and fix some omissionsBrad Fitzpatrick2016-09-271-0/+2
| | | | | | | | | | | | | It wasn't lowercasing the string, folding widths, and putting strings into NFC form. Do those. Fixes #13835 Change-Id: Ia3de6159417cacec203b48e206e51d79f945df58 Reviewed-on: https://go-review.googlesource.com/29860 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Marcel van Lohuizen <mpvl@golang.org>
* database/sql: add context methodsDaniel Theophanes2016-09-271-2/+2
| | | | | | | | | | | | | | | | | | | | Add context methods to sql and sql/driver methods. If the driver doesn't implement context methods the connection pool will still handle timeouts when a query fails to return in time or when a connection is not available from the pool in time. There will be a follow-up CL that will add support for context values that specify transaction levels and modes that a driver can use. Fixes #15123 Change-Id: Ia99f3957aa3f177b23044dd99d4ec217491a30a7 Reviewed-on: https://go-review.googlesource.com/29381 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
* go/doc: add IsPredeclared functionLuigi Riefolo2016-09-271-0/+5
| | | | | | | | IsPredeclared allows simplifying src/golang.org/x/tools/godoc/linkify.go Change-Id: I56b3223896f844630bc2e940255572d1682f0d06 Reviewed-on: https://go-review.googlesource.com/29870 Reviewed-by: Robert Griesemer <gri@golang.org>
* go/ast: better documentation for CallExpr nodeRobert Griesemer2016-09-261-1/+1
| | | | | | | | | Fixes #17222. Change-Id: Iffffc8cbb8627d06afa9066246b68fa2da4600e3 Reviewed-on: https://go-review.googlesource.com/29810 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* cmd/printer: document that Fprint doesn't match gofmt outputRobert Griesemer2016-09-261-0/+2
| | | | | | | | Fixes #16963. Change-Id: Iaadf0da4ee9cc97146c5e6ac2d93de9ae6893880 Reviewed-on: https://go-review.googlesource.com/29790 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* plugin: new package for loading pluginsDavid Crawshaw2016-09-161-0/+1
| | | | | | | | | | Includes a linux implementation. Change-Id: Iacc2ed7da760ae9deebc928adf2b334b043b07ec Reviewed-on: https://go-review.googlesource.com/27823 Run-TryBot: David Crawshaw <crawshaw@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
* net/http: update bundled x/net/http2Brad Fitzpatrick2016-09-131-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Updates x/net/http2 (and x/net/lex/httplex) to git rev 749a502 for: http2: don't sniff first Request.Body byte in Transport until we have a conn https://golang.org/cl/29074 Fixes #17071 http2: add Transport support for unicode domain names https://golang.org/cl/29071 Updates #13835 http2: don't send bogus :path pseudo headers if Request.URL.Opaque is set https://golang.org/cl/27632 + http2: fix bug where '*' as a valid :path value in Transport https://golang.org/cl/29070 Updates #16847 http2: fix all vet warnings https://golang.org/cl/28344 Updates #16228 Updates #11041 Also uses the new -underscore flag to x/tools/cmd/bundle from https://golang.org/cl/29086 Change-Id: Ica0f6bf6e33266237e37527a166a783d78c059c4 Reviewed-on: https://go-review.googlesource.com/29110 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Chris Broadfoot <cbro@golang.org>
* go/build: add help info for unset $GOPATHEdward Muller2016-09-101-1/+1
| | | | | | | | | | | | | We relay this info in a few places, in a few different ways, but not consistently everywhere. This led one of our users to start googling and not find https://golang.org/doc/code.html#Workspaces, of which `go help gopath` is the most equivalent. Change-Id: I28a94375739f3aa4f200e145293ca2a5f65101e1 Reviewed-on: https://go-review.googlesource.com/28690 Run-TryBot: Rob Pike <r@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Rob Pike <r@golang.org>
* go/format: add format.Node exampleAlberto Donizetti2016-09-081-0/+27
| | | | | | | | | Updates #16360 Change-Id: I5927cffa961cd85539a3ba9606b116c5996d1096 Reviewed-on: https://go-review.googlesource.com/26696 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
* go/constant: document that Value.String and ExactString return quoted stringsRobert Griesemer2016-09-071-2/+3
| | | | | | | | | | | | | This has always been the case but it was not obvious from the documentation. The reason for the quoting is that String() may return an abbreviated string, starting with double-quote (") but ending in ... (w/o a quote). The missing quote indicates the abbreviation (in contrast to a string ending in ..."). constant.StringVal can be used to obtain the unquoted string of a String Value. Change-Id: Id0ba45b6ff62b3e024386ba8d907d6b3a4fcb6d7 Reviewed-on: https://go-review.googlesource.com/28576 Reviewed-by: Alan Donovan <adonovan@google.com>
* net/http/httputil: make ReverseProxy send nil Body requests when possibleBrad Fitzpatrick2016-09-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | The http.Transport's retry can't retry requests with non-nil bodies. When cloning an incoming server request into an outgoing client request, nil out the Body field if the ContentLength is 0. (For server requests, Body is always non-nil, even for GET, HEAD, etc.) Also, don't use the deprecated CancelRequest and use Context instead. And don't set Proto, ProtoMajor, ProtoMinor. Those are ignored in client requests, which was probably a later documentation clarification. Fixes #16036 Updates #16696 (remove useless Proto lines) Change-Id: I70a869e9bd4bf240c5838e82fb5aa695a539b343 Reviewed-on: https://go-review.googlesource.com/28412 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Joe Tsai <thebrokentoaster@gmail.com>
* go/doc: allow ToHTML to properly handle URLs containing semicolonsMatt Layher2016-09-012-1/+2
| | | | | | | | | | Fixes #16565 Change-Id: I3edfd2576a7ca5270644a4e7f126854f821f2c9a Reviewed-on: https://go-review.googlesource.com/25385 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
* all: use testing.GoToolPath instead of "go"Keith Randall2016-08-301-2/+1
| | | | | | | | | | | | | | This change makes sure that tests are run with the correct version of the go tool. The correct version is the one that we invoked with "go test", not the one that is first in our path. Fixes #16577 Change-Id: If22c8f8c3ec9e7c35d094362873819f2fbb8559b Reviewed-on: https://go-review.googlesource.com/28089 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Keith Randall <khr@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
* go/types: fix bad variable shadowing in offsetsofJosh Bleecher Snyder2016-08-302-1/+30
| | | | | | | | | | | | Introduced in CL 26995. Fixes #16902 Change-Id: I8e749f598167e1f8b82cd5e735a7eb5291362e5e Reviewed-on: https://go-review.googlesource.com/28070 Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Robert Griesemer <gri@golang.org>
* cmd/compile: remove ignored bool from exported ODCL nodesRobert Griesemer2016-08-291-2/+2
| | | | | | | | | | | | | This shortens the export format by 1 byte for each exported ODCL node in inlined function bodies. Maintain backward compatibility by updating format version and continue to accept older format. Change-Id: I549bb3ade90bc0f146decf8016d5c9c3f14eb293 Reviewed-on: https://go-review.googlesource.com/27999 Run-TryBot: Robert Griesemer <gri@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/internal/gcimporter: fail gracefully on export format skewRobert Griesemer2016-08-266-30/+158
| | | | | | | | | | | | | | | | | | Port of changes made to compiler in https://go-review.googlesource.com/27814. Correctly handle export format version 0 (we only do this in x/tools/gcimporter15 at the moment - this is a backport of that code for struct fields). Added tests for version handling and detection of corrupted export data. Fixes #16881. Change-Id: I246553c689c89ef5c7fedd1e43717504c2838804 Reviewed-on: https://go-review.googlesource.com/27816 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* cmd/compile: export package for _ (blank) struct fieldsRobert Griesemer2016-08-231-7/+3
| | | | | | | | | | | | | | Blank struct fields are regular unexported fields. Two blank fields are different if they are from different packages. In order to correctly differentiate them, the compiler needs the package information. Add it to the export data. Fixes #15514. Change-Id: I421aaca22b542fcd0d66b2d2db777249cad78df6 Reviewed-on: https://go-review.googlesource.com/27639 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* internal/testenv: add HasSymlink/MustHaveSymlinkHiroshi Ioka2016-08-231-1/+1
| | | | | | | | | | | os package and path/filepath package have duplicated code for checking symlink supports in test code. This CL tries to simplify such test code. Change-Id: I0371488337f5e951eca699852daab9ccb16ddd62 Reviewed-on: https://go-review.googlesource.com/27331 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
* cmd/compile: clean up encoding of export version infoRobert Griesemer2016-08-221-17/+37
| | | | | | | | | | | | | | | Replace ad-hoc encoding of export version info with a more systematic approach. Continue to read (but not write) the Go1.7 format for backward- compatibility. This will avoid spurious errors with old installed packages. Fixes #16244. Change-Id: I945e79ffd5e22b883250f6f9fac218370c2505a2 Reviewed-on: https://go-review.googlesource.com/27452 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* cmd/compile/internal/syntax: match old parser errors and line numbersMatthew Dempsky2016-08-191-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | This makes a bunch of changes to package syntax to tweak line numbers for AST nodes. For example, short variable declaration statements are now associated with the location of the ":=" token, and function calls are associated with the location of the final ")" token. These help satisfy many unit tests that assume the old parser's behavior. Because many of these changes are questionable, they're guarded behind a new "gcCompat" const to make them easy to identify and revisit in the future. A handful of remaining tests are too difficult to make behave identically. These have been updated to execute with -newparser=0 and comments explaining why they need to be fixed. all.bash now passes with both the old and new parsers. Change-Id: Iab834b71ca8698d39269f261eb5c92a0d55a3bf4 Reviewed-on: https://go-review.googlesource.com/27199 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Robert Griesemer <gri@golang.org>
* go/types: better doc string for Object.Parent and testRobert Griesemer2016-08-182-1/+72
| | | | | | | | Fixes #14647. Change-Id: Ib9012a9141e815f5b95f8ca2307e65ffc4587a5b Reviewed-on: https://go-review.googlesource.com/27370 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/types: fix scope extents for range and type switch variablesRobert Griesemer2016-08-182-12/+43
| | | | | | | | | | | The changes match the existing compilers, and assume an adjusted spec (per issue #16794). Fixes #15686. Change-Id: I72677ce75888c41a8f3c2963117a2f2d5501c42b Reviewed-on: https://go-review.googlesource.com/27290 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/types: set Info.Types.Type for array composite literals of the form [...]TRobert Griesemer2016-08-182-1/+57
| | | | | | | | Fixes #14092. Change-Id: I00692f60a416348e38cab256b94fda07e334d258 Reviewed-on: https://go-review.googlesource.com/27316 Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/types: enable disabled test for comma-ok expressionsRobert Griesemer2016-08-171-7/+5
| | | | | | | | | | | | This was fixed long ago but the test was not enabled. For #8189. Change-Id: Ia44ef752b6bf076f3e243d2d0db326a392a20193 Reviewed-on: https://go-review.googlesource.com/27310 Run-TryBot: Robert Griesemer <gri@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
* go/types: better error message for invalid fallthrough caseRobert Griesemer2016-08-172-5/+25
| | | | | | | | | | | | Now matches the gc compiler. Fixes #15594. Change-Id: I9f3942367bc0acf883c6216b8ca44820832f5fe3 Reviewed-on: https://go-review.googlesource.com/27241 TryBot-Result: Gobot Gobot <gobot@golang.org> Run-TryBot: Robert Griesemer <gri@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
* go/build: introduce go1.8 build tagJoe Tsai2016-08-172-1/+2
| | | | | | | | Change-Id: Ib8855f8125970fc7ffb271635c28d31d310fcb5b Reviewed-on: https://go-review.googlesource.com/27192 Run-TryBot: Joe Tsai <thebrokentoaster@gmail.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
* cmd/compile: remove conditional code dealing with two export formatsRobert Griesemer2016-08-171-8/+3
| | | | | | | | | | | | | | | This removes some scaffolding introduced pre-1.7, introduced to fix an export format bug, and to minimize conflicts with older formats. The currently deployed and recognized format is "v1", so don't worry about other versions. This is a step towards a better scheme for internal export format versioning. For #16244. Change-Id: Ic7cf99dd2a24ad5484cc54aed44fa09332c2cf72 Reviewed-on: https://go-review.googlesource.com/27205 Reviewed-by: Matthew Dempsky <mdempsky@google.com> Run-TryBot: Robert Griesemer <gri@golang.org>