]> Cypherpunks repositories - gostls13.git/log
gostls13.git
14 years agopath: fix typo in path.Visitor
Andrew Gerrand [Wed, 8 Sep 2010 23:24:27 +0000 (09:24 +1000)]
path: fix typo in path.Visitor

Fixes #1088.

R=gri, iant
CC=golang-dev
https://golang.org/cl/2157043

14 years agotest: Recognize gccgo error messages.
Ian Lance Taylor [Wed, 8 Sep 2010 20:58:09 +0000 (13:58 -0700)]
test: Recognize gccgo error messages.

bug299.go:16:2: error: expected field name
bug299.go:17:2: error: expected field name
bug299.go:18:3: error: expected field name
bug299.go:25:9: error: expected receiver name or type
bug299.go:26:10: error: expected receiver name or type
bug299.go:27:9: error: expected receiver name or type

R=rsc
CC=golang-dev
https://golang.org/cl/2150044

14 years agotest: Match gccgo error messages.
Ian Lance Taylor [Wed, 8 Sep 2010 20:57:12 +0000 (13:57 -0700)]
test: Match gccgo error messages.

bug298.go:10:2: error: expected declaration
bug298.go:10:25: error: expected ‘;’ or newline after top level declaration
bug298.go:10:25: error: expected declaration

R=rsc
CC=golang-dev
https://golang.org/cl/2156046

14 years agotest: Actually run bug296.
Ian Lance Taylor [Wed, 8 Sep 2010 20:56:49 +0000 (13:56 -0700)]
test: Actually run bug296.

R=rsc
CC=golang-dev
https://golang.org/cl/2156045

14 years agohttp: do not cache CanonicalHeaderKey
Jukka-Pekka Kekkonen [Wed, 8 Sep 2010 14:20:21 +0000 (10:20 -0400)]
http: do not cache CanonicalHeaderKey

Fixes #1080.

R=rsc
CC=golang-dev
https://golang.org/cl/2158043

14 years agogc: better printing of named constants, func literals
Russ Cox [Wed, 8 Sep 2010 14:12:56 +0000 (10:12 -0400)]
gc: better printing of named constants, func literals

R=ken2
CC=golang-dev
https://golang.org/cl/2121045

14 years agogodoc: moved package directory support code into separate file
Robert Griesemer [Wed, 8 Sep 2010 00:21:00 +0000 (17:21 -0700)]
godoc: moved package directory support code into separate file

- in prep. for some restructuring to be able to better deal
  with very large file systems
- moved a utility function into index.go
- no functionality changes, only code reorg.

R=r, adg1
CC=golang-dev
https://golang.org/cl/2098044

14 years agogo_spec: consistent use of 'low', 'high' in slices section
Robert Griesemer [Tue, 7 Sep 2010 23:32:35 +0000 (16:32 -0700)]
go_spec: consistent use of 'low', 'high' in slices section

Also: Added examples for slices with omitted index expressions.

R=r, rsc
CC=golang-dev
https://golang.org/cl/2106047

14 years agospec: Allow omission of low slice bound
Scott Lawrence [Tue, 7 Sep 2010 21:30:17 +0000 (14:30 -0700)]
spec: Allow omission of low slice bound

See also https://golang.org/cl/1957045/

R=gri, rsc, r
CC=golang-dev
https://golang.org/cl/2163042

14 years agoos, exec: rename argv0 to name
Russ Cox [Tue, 7 Sep 2010 20:29:07 +0000 (16:29 -0400)]
os, exec: rename argv0 to name

R=r, gri1
CC=golang-dev
https://golang.org/cl/2119044

14 years agobuild: work with GNU Make 3.82
Jukka-Pekka Kekkonen [Tue, 7 Sep 2010 19:14:14 +0000 (15:14 -0400)]
build: work with GNU Make 3.82

Fix building on GNU Make 3.82 (caused by mixed implicit and normal
rules).

The issue was introduced in changeset 6110:ca0beac3b543.

R=rsc
CC=golang-dev
https://golang.org/cl/2100044

14 years agogo_spec: fix typo (pointed out by Hiroshi Iwatani)
Robert Griesemer [Tue, 7 Sep 2010 18:14:36 +0000 (11:14 -0700)]
go_spec: fix typo (pointed out by Hiroshi Iwatani)

R=iant
CC=golang-dev
https://golang.org/cl/2128045

14 years agoruntime: fix linux/amd64 build: wrong name for munmap
Russ Cox [Tue, 7 Sep 2010 17:17:10 +0000 (13:17 -0400)]
runtime: fix linux/amd64 build: wrong name for munmap

TBR=r
CC=golang-dev
https://golang.org/cl/2140043

14 years agoruntime: use manual stack for garbage collection
Russ Cox [Tue, 7 Sep 2010 13:57:22 +0000 (09:57 -0400)]
runtime: use manual stack for garbage collection

Old code was using recursion to traverse object graph.
New code uses an explicit stack, cutting the per-pointer
footprint to two words during the recursion and avoiding
the standard allocator and stack splitting code.

in test/garbage:

Reduces parser runtime by 2-3%
Reduces Peano runtime by 40%
Increases tree runtime by 4-5%

R=r
CC=golang-dev
https://golang.org/cl/2150042

14 years agotest/garbage/parser: sync with recent parser changes
Russ Cox [Tue, 7 Sep 2010 13:55:05 +0000 (09:55 -0400)]
test/garbage/parser: sync with recent parser changes

R=gri
CC=golang-dev
https://golang.org/cl/2144042

14 years agocgo: silence warning for C call returning const pointer
Russ Cox [Tue, 7 Sep 2010 13:54:20 +0000 (09:54 -0400)]
cgo: silence warning for C call returning const pointer

Fix suggested by Albert Strasheim.

R=adg
CC=golang-dev
https://golang.org/cl/2154041

14 years agoexp/draw: reintroduce the MouseEvent.Nsec timestamp.
Nigel Tao [Tue, 7 Sep 2010 13:42:01 +0000 (23:42 +1000)]
exp/draw: reintroduce the MouseEvent.Nsec timestamp.

R=rsc
CC=golang-dev
https://golang.org/cl/2166042

14 years agoarm: use the correct stat syscalls
Brad Fitzpatrick [Tue, 7 Sep 2010 13:23:49 +0000 (09:23 -0400)]
arm: use the correct stat syscalls

We were using the 64-bit struct with the old 32-bit
system calls.

http://code.google.com/p/go/issues/detail?id=1083

This also fixes up mksyscall.sh to generate
gofmt-compliant code.

R=rsc
CC=golang-dev, kaib
https://golang.org/cl/2148042

14 years agoimage: change a ColorImage's minimum point from (0, 0) to (-1e9, -1e9).
Nigel Tao [Tue, 7 Sep 2010 09:16:59 +0000 (19:16 +1000)]
image: change a ColorImage's minimum point from (0, 0) to (-1e9, -1e9).

R=r
CC=golang-dev
https://golang.org/cl/2138045

14 years agotag release.2010-09-06
Andrew Gerrand [Tue, 7 Sep 2010 06:17:14 +0000 (16:17 +1000)]
tag release.2010-09-06

R=r
CC=golang-dev
https://golang.org/cl/2165042

14 years agorelease.2010-09-06 weekly.2010-09-06
Andrew Gerrand [Tue, 7 Sep 2010 06:09:20 +0000 (16:09 +1000)]
release.2010-09-06

R=r
CC=golang-dev
https://golang.org/cl/2141043

14 years agoexp/draw: unify a draw.Context's keyboard, mouse, etc. channels into a
Nigel Tao [Mon, 6 Sep 2010 09:22:49 +0000 (19:22 +1000)]
exp/draw: unify a draw.Context's keyboard, mouse, etc. channels into a
single event channel.

A quit event is now represented by closing that channel.

R=r, rsc, nigeltao
CC=golang-dev
https://golang.org/cl/2114042

14 years agofmt.Scan: fix integer overflow on 32-bit machines
Anthony Martin [Sun, 5 Sep 2010 22:04:53 +0000 (08:04 +1000)]
fmt.Scan: fix integer overflow on 32-bit machines

R=r, rsc
CC=golang-dev
https://golang.org/cl/2144043

14 years agonetchan: use acknowledgements on export send.
Rob Pike [Sat, 4 Sep 2010 13:41:54 +0000 (23:41 +1000)]
netchan: use acknowledgements on export send.
Also add exporter.Drain() to wait for completion.
This makes it possible for an Exporter to fire off a message
and wait (by calling Drain) for the message to be received,
even if a client has yet to call to retrieve it.

Once this design is settled, I'll do the same for import send.

Testing strategies welcome.  I have some working stand-alone
tests.

R=rsc
CC=golang-dev
https://golang.org/cl/2137041

14 years agofmt: delete erroneous sentence about return value for Sprint*.
Rob Pike [Sat, 4 Sep 2010 12:29:10 +0000 (22:29 +1000)]
fmt: delete erroneous sentence about return value for Sprint*.

R=rsc
CC=golang-dev
https://golang.org/cl/2160041

14 years agotest/turing: refactor
Rob Pike [Sat, 4 Sep 2010 00:40:00 +0000 (10:40 +1000)]
test/turing: refactor

R=gri
CC=golang-dev
https://golang.org/cl/2116043

14 years agotest: remove semiocolons.
Rob Pike [Sat, 4 Sep 2010 00:36:13 +0000 (10:36 +1000)]
test: remove semiocolons.
The ken directory is untouched so we have some examples with explicit semis.

R=gri
CC=golang-dev
https://golang.org/cl/2157041

14 years agotutorial: regenerate HTML to pick up change to progs/file.go.
Rob Pike [Sat, 4 Sep 2010 00:22:49 +0000 (10:22 +1000)]
tutorial: regenerate HTML to pick up change to progs/file.go.

Fixes #1075.

R=gri
CC=golang-dev
https://golang.org/cl/2104048

14 years agobuild: implement NOINSTALL=1 for Make.ccmd
Russ Cox [Fri, 3 Sep 2010 19:37:57 +0000 (15:37 -0400)]
build: implement NOINSTALL=1 for Make.ccmd

The makefiles for prof and cov use it already.
(It's also in Make.clib.)

R=adg
CC=golang-dev
https://golang.org/cl/2036045

14 years agogoinstall: assume go binaries are in path
Russ Cox [Fri, 3 Sep 2010 19:37:45 +0000 (15:37 -0400)]
goinstall: assume go binaries are in path

(Following new convention.)

Fixes #1063.

R=adg
CC=golang-dev
https://golang.org/cl/2115042

14 years agosolitaire: an exercise in backtracking and string conversions
Robert Griesemer [Fri, 3 Sep 2010 17:52:45 +0000 (10:52 -0700)]
solitaire: an exercise in backtracking and string conversions

Solves the (English) peg solitaire game. The board is represented
by a 1-dimensional array for easy representation of directions
with a single integer. The board's contents are chosen such that
it can be printed with a direct string() conversion.

R=r
CC=adg, golang-dev
https://golang.org/cl/2066042

14 years agorevert accidental submit of builder.go
Andrew Gerrand [Fri, 3 Sep 2010 08:08:16 +0000 (18:08 +1000)]
revert accidental submit of builder.go

R=rsc
CC=golang-dev
https://golang.org/cl/2121042

14 years agoimage: introduce Config type and DecodeConfig function, to decode an
Nigel Tao [Fri, 3 Sep 2010 08:03:08 +0000 (18:03 +1000)]
image: introduce Config type and DecodeConfig function, to decode an
image's color model and dimensions without allocating and decoding its
actual pixels.

Fixes #695.

R=r
CC=golang-dev
https://golang.org/cl/2151042

14 years agomisc/dashboard/builder: Go implementation of continuous build client
Andrew Gerrand [Fri, 3 Sep 2010 07:57:13 +0000 (17:57 +1000)]
misc/dashboard/builder: Go implementation of continuous build client

R=rsc, r
CC=golang-dev
https://golang.org/cl/2112042

14 years agolist: update comment to state that the zero value is ready to use.
Rob Pike [Fri, 3 Sep 2010 07:11:56 +0000 (17:11 +1000)]
list: update comment to state that the zero value is ready to use.

R=gri
CC=golang-dev
https://golang.org/cl/2147042

14 years agogc: appease bison version running on FreeBSD builder
Russ Cox [Thu, 2 Sep 2010 18:31:39 +0000 (14:31 -0400)]
gc: appease bison version running on FreeBSD builder

R=ken2
CC=golang-dev
https://golang.org/cl/2141042

14 years agoexp/iterables: fix typo
Robert Griesemer [Thu, 2 Sep 2010 18:31:00 +0000 (11:31 -0700)]
exp/iterables: fix typo

Fixes #1069.

R=rsc
CC=golang-dev
https://golang.org/cl/2143041

14 years agotime: do not crash in String on nil Time
Russ Cox [Thu, 2 Sep 2010 18:21:40 +0000 (14:21 -0400)]
time: do not crash in String on nil Time

R=r
CC=golang-dev
https://golang.org/cl/2052041

14 years agohttp: add Date to server, Last-Modified and If-Modified-Since to file server
Russ Cox [Thu, 2 Sep 2010 18:21:11 +0000 (14:21 -0400)]
http: add Date to server, Last-Modified and If-Modified-Since to file server

R=r
CC=golang-dev
https://golang.org/cl/2051041

14 years agobuild: create bin and pkg directories as needed; drop from hg
Russ Cox [Thu, 2 Sep 2010 18:20:02 +0000 (14:20 -0400)]
build: create bin and pkg directories as needed; drop from hg

R=dsymonds, r
CC=golang-dev
https://golang.org/cl/2050043

14 years agoruntime: add GOOS, GOARCH; fix FuncLine
Russ Cox [Thu, 2 Sep 2010 18:19:12 +0000 (14:19 -0400)]
runtime: add GOOS, GOARCH; fix FuncLine

Changes to FuncLine sync it with symtab.c's funcline.

R=r
CC=girard.m1, golang-dev
https://golang.org/cl/2083041

14 years agogc: fix spurious syntax error
Russ Cox [Thu, 2 Sep 2010 18:16:01 +0000 (14:16 -0400)]
gc: fix spurious syntax error

Fixes #1071.

R=ken2
CC=golang-dev
https://golang.org/cl/2136043

14 years agogoinstall: added -a flag to mean "all remote packages"
Scott Lawrence [Thu, 2 Sep 2010 17:48:28 +0000 (13:48 -0400)]
goinstall: added -a flag to mean "all remote packages"
Fixes #897.

goinstall -a can be used to reinstall all packages after an upgrade
goinstall -a -u can be used to update all package
A history of remote package installs is stored in $GOROOT/goinstall.log

R=rsc, adg
CC=golang-dev
https://golang.org/cl/1947041

14 years agogo spec clarification: arrays must be addressable to be sliceable
Robert Griesemer [Thu, 2 Sep 2010 17:16:31 +0000 (10:16 -0700)]
go spec clarification: arrays must be addressable to be sliceable

R=rsc
CC=golang-dev, r
https://golang.org/cl/2141041

14 years ago8l: suppress emitting DWARF in Windows PE.
Alex Brainman [Thu, 2 Sep 2010 07:00:24 +0000 (17:00 +1000)]
8l: suppress emitting DWARF in Windows PE.

Fixes #1064.

R=rsc, lvd, vcc
CC=golang-dev
https://golang.org/cl/2104042

14 years agotest: Match gccgo error messages.
Ian Lance Taylor [Thu, 2 Sep 2010 04:05:31 +0000 (21:05 -0700)]
test: Match gccgo error messages.

bug284.go:33: error: invalid type conversion
bug284.go:36: error: invalid type conversion (cannot use type A2 as type A1)
bug284.go:37: error: invalid type conversion
bug284.go:38: error: invalid type conversion (cannot use type A1 as type A2)
bug284.go:56: error: invalid type conversion
bug284.go:59: error: invalid type conversion (cannot use type S2 as type S1)
bug284.go:60: error: invalid type conversion
bug284.go:61: error: invalid type conversion (cannot use type S1 as type S2)
bug284.go:71: error: invalid type conversion
bug284.go:74: error: invalid type conversion (cannot use type P2 as type P1)
bug284.go:75: error: invalid type conversion
bug284.go:76: error: invalid type conversion (cannot use type P1 as type P2)
bug284.go:96: error: invalid type conversion
bug284.go:99: error: invalid type conversion (cannot use type Q2 as type Q1)
bug284.go:101: error: invalid type conversion (cannot use type Q1 as type Q2)
bug284.go:111: error: invalid type conversion (different parameter types)
bug284.go:114: error: invalid type conversion (different parameter types)
bug284.go:115: error: invalid type conversion (different parameter types)
bug284.go:116: error: invalid type conversion (different parameter types)
bug284.go:134: error: invalid type conversion (incompatible type for method 'f' (different result types))
bug284.go:137: error: invalid type conversion (incompatible type for method 'f' (different result types))
bug284.go:138: error: invalid type conversion (incompatible type for method 'f' (different result types))
bug284.go:139: error: invalid type conversion (incompatible type for method 'f' (different result types))
bug284.go:149: error: invalid type conversion
bug284.go:152: error: invalid type conversion (cannot use type L2 as type L1)
bug284.go:153: error: invalid type conversion
bug284.go:154: error: invalid type conversion (cannot use type L1 as type L2)
bug284.go:164: error: invalid type conversion
bug284.go:167: error: invalid type conversion (cannot use type L2 as type L1)
bug284.go:168: error: invalid type conversion
bug284.go:169: error: invalid type conversion (cannot use type L1 as type L2)
bug284.go:179: error: invalid type conversion
bug284.go:182: error: invalid type conversion (cannot use type C2 as type C1)
bug284.go:183: error: invalid type conversion
bug284.go:184: error: invalid type conversion (cannot use type C1 as type C2)

R=rsc
CC=golang-dev
https://golang.org/cl/2136041

14 years agotest: Recognize gccgo error messages.
Ian Lance Taylor [Thu, 2 Sep 2010 04:04:57 +0000 (21:04 -0700)]
test: Recognize gccgo error messages.

bug278.go:18: error: invalid left hand side of assignment
bug278.go:19: error: array is not addressable
bug278.go:21: error: invalid left hand side of assignment
bug278.go:22: error: invalid left hand side of assignment

R=rsc
CC=golang-dev
https://golang.org/cl/2122042

14 years agohttp: add PostForm function to post url-encoded key/value data.
Andrew Gerrand [Thu, 2 Sep 2010 00:01:34 +0000 (10:01 +1000)]
http: add PostForm function to post url-encoded key/value data.

This is a common task, so it makes sense to have a helper to do it.

(App Engine doesn't like "Transfer-Encoding: chunked" for POST
bodies, which is the default for regular Post.)

R=rsc
CC=golang-dev
https://golang.org/cl/2113041

14 years agoFix incorrect reporting of error in Scanner.next() when Read reads > 0 bytes but...
Kyle Consalus [Wed, 1 Sep 2010 22:15:37 +0000 (15:15 -0700)]
Fix incorrect reporting of error in Scanner.next() when Read reads > 0 bytes but returns os.EOF.

R=golang-dev, gri1, gri
CC=golang-dev
https://golang.org/cl/2083042

14 years agonetchan: rather than 0, make -1 mean infinite, by analogy with strings.Split etc.
Rob Pike [Wed, 1 Sep 2010 22:10:53 +0000 (08:10 +1000)]
netchan: rather than 0, make -1 mean infinite, by analogy with strings.Split etc.
It's unlikely to affect any extant code, but I wanted to make this API change
before digging in for a rewrite.

R=rsc
CC=golang-dev
https://golang.org/cl/2112041

14 years agotest: Use global variables to defeat gccgo optimizer.
Ian Lance Taylor [Wed, 1 Sep 2010 20:40:20 +0000 (13:40 -0700)]
test: Use global variables to defeat gccgo optimizer.

The gccgo compiler is smart enough to not make something which
is not used.  Use global variables to defeat this
optimization.

R=rsc
CC=golang-dev
https://golang.org/cl/2129041

14 years ago6l/8l: emit DWARF in macho.
Luuk van Dijk [Wed, 1 Sep 2010 19:54:28 +0000 (21:54 +0200)]
6l/8l: emit DWARF in macho.

R=rsc, r, ken2
CC=golang-dev
https://golang.org/cl/2128041

14 years agofmt: fix typo in package comment.
Rob Pike [Wed, 1 Sep 2010 12:59:20 +0000 (22:59 +1000)]
fmt: fix typo in package comment.
No semantic change.

R=rsc
CC=golang-dev
https://golang.org/cl/2121041

14 years agotemplate: fixed documentation formatting
Scott Lawrence [Wed, 1 Sep 2010 02:07:40 +0000 (19:07 -0700)]
template: fixed documentation formatting
What was meant to be a list appeared as a paragraph with dashes.

R=golang-dev, gri1, gri
CC=golang-dev
https://golang.org/cl/2100041

14 years agospec: delete spurious space (missed fix from previous review)
Rob Pike [Wed, 1 Sep 2010 00:48:45 +0000 (10:48 +1000)]
spec: delete spurious space (missed fix from previous review)
No semantic change.

R=rsc
CC=golang-dev
https://golang.org/cl/2099041

14 years agospec: fix a couple of tiny glitches
Rob Pike [Wed, 1 Sep 2010 00:40:50 +0000 (10:40 +1000)]
spec: fix a couple of tiny glitches

R=gri, rsc
CC=golang-dev
https://golang.org/cl/2078041

14 years agotest: Recognize gccgo error messages.
Ian Lance Taylor [Wed, 1 Sep 2010 00:38:11 +0000 (17:38 -0700)]
test: Recognize gccgo error messages.

bug255.go:11: error: array bound truncated to integer
bug255.go:12: error: array bound is not numeric
bug255.go:13: error: array bound is not numeric
bug255.go:14: error: array bound is not constant
bug255.go:15: error: array bound overflows

R=rsc
CC=golang-dev
https://golang.org/cl/2091042

14 years agotest: Match gccgo error messages.
Ian Lance Taylor [Tue, 31 Aug 2010 22:48:04 +0000 (15:48 -0700)]
test: Match gccgo error messages.

Another case where gccgo and gc report similar but not
identical errors for a recursive interface.

bug251.go:11: error: invalid recursive interface

R=rsc
CC=golang-dev
https://golang.org/cl/2094041

14 years agobig: added RatString, some simplifications
Robert Griesemer [Tue, 31 Aug 2010 22:18:46 +0000 (15:18 -0700)]
big: added RatString, some simplifications

R=rsc
CC=golang-dev
https://golang.org/cl/2095041

14 years agostrconv: fix comment for godoc
Robert Griesemer [Tue, 31 Aug 2010 21:18:20 +0000 (14:18 -0700)]
strconv: fix comment for godoc

R=rsc
CC=golang-dev
https://golang.org/cl/2029042

14 years agotest: gccgo and gc print the error on different lines.
Ian Lance Taylor [Tue, 31 Aug 2010 21:12:23 +0000 (14:12 -0700)]
test: gccgo and gc print the error on different lines.

This introduces GC_ERROR to mark an error only issued by the
gc compiler.  GCCGO_ERROR already exists to mark errors only
issued by the gccgo compiler.  Obviously these should be used
sparingly.

bug195.go:9: error: interface contains embedded non-interface
bug195.go:12: error: interface contains embedded non-interface
bug195.go:15: error: interface contains embedded non-interface
bug195.go:18: error: invalid recursive interface
bug195.go:22: error: invalid recursive interface

R=rsc
CC=golang-dev
https://golang.org/cl/2040043

14 years agotest: Match gccgo error messages.
Ian Lance Taylor [Tue, 31 Aug 2010 18:43:52 +0000 (11:43 -0700)]
test: Match gccgo error messages.

gcc conventionally does not upper case in error messages.

char_lit1.go:13: error: invalid unicode code point 0xd800
char_lit1.go:14: error: invalid unicode code point 0xd999
char_lit1.go:15: error: invalid unicode code point 0xdc01
char_lit1.go:16: error: invalid unicode code point 0xdddd
char_lit1.go:17: error: invalid unicode code point 0xdfff
char_lit1.go:20: error: invalid unicode code point 0x110000
char_lit1.go:22: error: invalid unicode code point 0x110000
char_lit1.go:23: error: invalid unicode code point 0xffffffff

R=rsc
CC=golang-dev
https://golang.org/cl/2040042

14 years agotest: don't assign address of array to slice.
Ian Lance Taylor [Tue, 31 Aug 2010 14:34:01 +0000 (07:34 -0700)]
test: don't assign address of array to slice.

R=rsc
CC=golang-dev
https://golang.org/cl/2084042

14 years agomisc/bash: add *.go completion for gofmt
Scott Lawrence [Tue, 31 Aug 2010 01:13:11 +0000 (21:13 -0400)]
misc/bash: add *.go completion for gofmt

R=golang-dev, rsc1, rsc
CC=golang-dev
https://golang.org/cl/2039044

14 years agomisc: add zsh completion (using compctl)
Scott Lawrence [Tue, 31 Aug 2010 01:13:01 +0000 (21:13 -0400)]
misc: add zsh completion (using compctl)

R=golang-dev, rsc1, rsc
CC=golang-dev
https://golang.org/cl/2061042

14 years agodoc: add round-robin flag to io2010 balance example.
Nigel Tao [Tue, 31 Aug 2010 01:00:43 +0000 (11:00 +1000)]
doc: add round-robin flag to io2010 balance example.

R=r
CC=golang-dev
https://golang.org/cl/2050042

14 years agoproc, eval: Don't assign address of an array to a slice.
Ian Lance Taylor [Mon, 30 Aug 2010 20:47:40 +0000 (13:47 -0700)]
proc, eval: Don't assign address of an array to a slice.

R=rsc
CC=golang-dev
https://golang.org/cl/2084041

14 years ago8l: emit DWARF in ELF.
Luuk van Dijk [Mon, 30 Aug 2010 20:20:38 +0000 (22:20 +0200)]
8l: emit DWARF in ELF.

R=rsc, r, ken2
CC=golang-dev
https://golang.org/cl/2004046

14 years agobuild: remove unnecessary references to GOBIN and GOROOT
Christian Himpel [Mon, 30 Aug 2010 19:40:56 +0000 (15:40 -0400)]
build: remove unnecessary references to GOBIN and GOROOT

All scripts and makefiles assume that GOBIN is correctly set
in PATH.

R=rsc
CC=golang-dev
https://golang.org/cl/2043041

14 years agomisc/fraise: syntax highlighting for Fraise.app (OS X)
Vincent Ambo [Mon, 30 Aug 2010 05:07:33 +0000 (15:07 +1000)]
misc/fraise: syntax highlighting for Fraise.app (OS X)

R=golang-dev, adg1, adg
CC=golang-dev
https://golang.org/cl/2075041

14 years agoA+C: Vincent Ambo
Andrew Gerrand [Mon, 30 Aug 2010 04:57:23 +0000 (14:57 +1000)]
A+C: Vincent Ambo

R=r
CC=golang-dev
https://golang.org/cl/2048043

14 years agoregexp: interpret all Go characer escapes \a \b \f \n \r \t \v
Rob Pike [Mon, 30 Aug 2010 04:06:59 +0000 (14:06 +1000)]
regexp: interpret all Go characer escapes \a \b \f \n \r \t \v

R=rsc
CC=golang-dev
https://golang.org/cl/2042044

14 years agocodereview: Fix uploading for Mercurial 1.6.3
Evan Shaw [Mon, 30 Aug 2010 03:04:05 +0000 (23:04 -0400)]
codereview: Fix uploading for Mercurial 1.6.3

See:
http://selenic.com/repo/hg/rev/32b213b9b22c
http://selenic.com/repo/hg/rev/2096496b40ec

R=rsc, adg
CC=golang-dev
https://golang.org/cl/2072041

14 years agocrypto/tls: Fix doc typo
Evan Shaw [Sun, 29 Aug 2010 23:59:59 +0000 (09:59 +1000)]
crypto/tls: Fix doc typo

R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/2073041

14 years agodoc: various changes for validating HTML
Scott Lawrence [Sun, 29 Aug 2010 23:58:27 +0000 (09:58 +1000)]
doc: various changes for validating HTML
(Fixes missing tags, extra tags, missing attributes, and such found by tidy -e)

R=golang-dev, adg1, adg
CC=golang-dev
https://golang.org/cl/2039043

14 years agorpc: fix bug that caused private methods to attempt to be registered.
Rob Pike [Sun, 29 Aug 2010 22:03:06 +0000 (08:03 +1000)]
rpc: fix bug that caused private methods to attempt to be registered.

Fixes #1056.

R=golang-dev, adg1
CC=golang-dev
https://golang.org/cl/2033043

14 years ago Documentation: Fix a bug in the example in Constants subsection
James Fysh [Fri, 27 Aug 2010 21:54:16 +0000 (07:54 +1000)]
Documentation: Fix a bug in the example in Constants subsection

Not a bug per-se, the issue is that the fmt.Sprintf method inside the
ByteSize.String() method ends up calling itself to generate the String
representation of the ByteSize value.  Infinite loops are bad.

    Updated as per review comments

R=r
CC=golang-dev
https://golang.org/cl/1974046

14 years agotemplate: finally fix space handling around actions.
Rob Pike [Fri, 27 Aug 2010 21:52:55 +0000 (07:52 +1000)]
template: finally fix space handling around actions.
Rewrite the code to express the intention more clearly.

Fixes #1042.

R=rsc
CC=golang-dev
https://golang.org/cl/2011046

14 years agoCLA: Add James Fysh
Rob Pike [Fri, 27 Aug 2010 21:52:22 +0000 (07:52 +1000)]
CLA: Add James Fysh

R=gri
CC=James Fysh, golang-dev
https://golang.org/cl/2043042

14 years agogofmt: permit omission of first index in slice expression
Robert Griesemer [Fri, 27 Aug 2010 21:49:49 +0000 (14:49 -0700)]
gofmt: permit omission of first index in slice expression

R=rsc
CC=golang-dev, r
https://golang.org/cl/2053041

14 years ago8g: use FCHS, not FMUL, for minus float
Russ Cox [Fri, 27 Aug 2010 18:02:00 +0000 (14:02 -0400)]
8g: use FCHS, not FMUL, for minus float

Fixes #1052.

R=ken2
CC=golang-dev
https://golang.org/cl/2055041

14 years agogo/printer: align ImportPaths in ImportDecls if PackageName is given.
Scott Lawrence [Fri, 27 Aug 2010 05:08:02 +0000 (22:08 -0700)]
go/printer: align ImportPaths in ImportDecls if PackageName is given.
Fixes #1044.

R=gri
CC=golang-dev
https://golang.org/cl/1958047

14 years agodoc: fix margins in root.html
Andrew Gerrand [Fri, 27 Aug 2010 04:14:42 +0000 (14:14 +1000)]
doc: fix margins in root.html

R=rsc, r2
CC=golang-dev
https://golang.org/cl/2041041

14 years agodoc: remove console.log line from root.html
Andrew Gerrand [Fri, 27 Aug 2010 03:46:59 +0000 (13:46 +1000)]
doc: remove console.log line from root.html

R=r, rsc1
CC=golang-dev
https://golang.org/cl/2040041

14 years agodoc: fix wiki codelab title and srcextract.go
Andrew Gerrand [Fri, 27 Aug 2010 01:02:54 +0000 (11:02 +1000)]
doc: fix wiki codelab title and srcextract.go

R=r, rsc1
CC=golang-dev
https://golang.org/cl/1953048

14 years agoMake.pkg: never use quietgcc
Russ Cox [Fri, 27 Aug 2010 00:21:34 +0000 (20:21 -0400)]
Make.pkg: never use quietgcc

R=iant
CC=golang-dev
https://golang.org/cl/2033041

14 years agomath: amd64 version of Sincos
Charles L. Dorian [Thu, 26 Aug 2010 23:03:58 +0000 (19:03 -0400)]
math: amd64 version of Sincos

R=rsc
CC=golang-dev
https://golang.org/cl/1939042

14 years agocodereview: speed upload
Russ Cox [Thu, 26 Aug 2010 22:56:29 +0000 (18:56 -0400)]
codereview: speed upload

Cuts time to upload trivial 160-file CL by 5x,
from 250 seconds to 50 seconds.

R=r
CC=golang-dev
https://golang.org/cl/1991047

14 years agobuild: fix cgo with -j2
Russ Cox [Thu, 26 Aug 2010 22:47:34 +0000 (18:47 -0400)]
build: fix cgo with -j2

a b: c expands to multiple rules,
which then run in parallel.

R=r, iant
CC=golang-dev
https://golang.org/cl/2007047

14 years agogc: brace nit from last review
Kyle Consalus [Thu, 26 Aug 2010 22:46:56 +0000 (18:46 -0400)]
gc: brace nit from last review

R=rsc
CC=golang-dev
https://golang.org/cl/1997045

14 years agonetchan: Fix race condition in test.
Ian Lance Taylor [Thu, 26 Aug 2010 22:42:18 +0000 (15:42 -0700)]
netchan: Fix race condition in test.

Two tests start a goroutine which runs exportSend, and then
the tests run importReceive.  exportSend creates an export
channel.  importReceive asks to receive values on that
channel.  Because exportSend runs in a separate goroutine,
it's possible for the export client to receive the request for
values on the channel, from importReceive, before the
goroutine actually creates the export channel.  That causes an
error: "export: no such channel: exportedSend".  This patch
avoids the race by creating the export channel before starting
the goroutine.

There does not seem to be a similar race condition in the
tests which send data in the other direction.

R=r
CC=golang-dev
https://golang.org/cl/2026045

14 years agocodereview: consistent indent, cut dead code
Russ Cox [Thu, 26 Aug 2010 22:24:14 +0000 (18:24 -0400)]
codereview: consistent indent, cut dead code

End the charade (farce?) that we are using upload.py unaltered.
Cut all the unused stuff.
Indent using tabs to match the rest of the file.

Next: rewrite MercurialVCS to use mercurial package,
to avoid overhead of forking off a new hg command
multiple times for every file.  And parallelize upload.

R=gri
CC=golang-dev
https://golang.org/cl/2009046

14 years agogo/typechecker: 2nd step towards augmenting AST with full type information.
Robert Griesemer [Thu, 26 Aug 2010 21:36:13 +0000 (14:36 -0700)]
go/typechecker: 2nd step towards augmenting AST with full type information.

- refine/define Scope, Object, and Type structures
  (note: scope.go has the addition of types, the rest is only re-organized
  for better readability)
- implemented top-level of type checker:
  resolve global type declarations (deal with double decls, cycles, etc.)
- temporary hooks for checking of const/var declarations, function/method bodies
- test harness for fine-grained testing (exact error locations)
  with initial set of tests

This is a subset of the code for easier review.

R=rsc
CC=golang-dev
https://golang.org/cl/1967049

14 years agocodereview: fix hang on standard hg commands
Russ Cox [Thu, 26 Aug 2010 21:06:36 +0000 (17:06 -0400)]
codereview: fix hang on standard hg commands

R=gri
CC=golang-dev
https://golang.org/cl/1950045

14 years agocodereview: print status when hung
Russ Cox [Thu, 26 Aug 2010 20:27:42 +0000 (16:27 -0400)]
codereview: print status when hung

After 30 seconds, start printing status updates,
so that we can see whether hg is making progress.

$ hg upload 1983051
Thu Aug 26 15:06:15 2010 running gofmt
Thu Aug 26 15:06:30 2010 inspecting src/pkg/big/int_test.go
Thu Aug 26 15:06:45 2010 inspecting src/pkg/cmath/conj.go
Thu Aug 26 15:07:00 2010 inspecting src/pkg/expvar/expvar.go
Thu Aug 26 15:07:15 2010 inspecting src/pkg/os/env_unix.go
Thu Aug 26 15:07:30 2010 inspecting src/pkg/os/sys_bsd.go
Thu Aug 26 15:07:45 2010 inspecting src/pkg/rand/rand_test.go
Thu Aug 26 15:08:00 2010 inspecting src/pkg/runtime/sig.go
Thu Aug 26 15:08:15 2010 inspecting src/pkg/time/time_test.go
Thu Aug 26 15:08:30 2010 inspecting src/pkg/websocket/websocket.go
Thu Aug 26 15:08:45 2010 uploading src/pkg/utf8/utf8.go
Thu Aug 26 15:09:00 2010 uploading src/pkg/unicode/letter_test.go
Thu Aug 26 15:09:15 2010 uploading src/pkg/xml/embed_test.go
Thu Aug 26 15:09:30 2010 uploading src/pkg/time/tick.go
Thu Aug 26 15:09:45 2010 uploading src/pkg/big/rat_test.go
Thu Aug 26 15:10:00 2010 uploading src/pkg/time/sleep_test.go
Thu Aug 26 15:10:15 2010 uploading src/pkg/patch/patch_test.go
Thu Aug 26 15:10:30 2010 uploading src/pkg/rand/rand.go
https://golang.org/cl/1983051

$

R=gri
CC=golang-dev
https://golang.org/cl/2020045

14 years agomisc/emacs: make _ a word symbol
Scott Lawrence [Thu, 26 Aug 2010 17:32:50 +0000 (13:32 -0400)]
misc/emacs: make _ a word symbol

Fixes #655.

R=rsc, aclements
CC=golang-dev
https://golang.org/cl/1981041

14 years agonet: add LookupMX
Corey Thomasson [Thu, 26 Aug 2010 17:32:45 +0000 (13:32 -0400)]
net: add LookupMX

R=rsc
CC=golang-dev
https://golang.org/cl/1976049

14 years agoruntime: special case copy, equal for one-word interface values
Kyle Consalus [Thu, 26 Aug 2010 17:32:40 +0000 (13:32 -0400)]
runtime: special case copy, equal for one-word interface values

Based on the observation that a great number of the types that
are copied or compared in interfaces, maps, and channels are
word-sized, this uses specialized copy and equality functions
for them that use a word instead of 4 or 8 bytes. Seems to yield
0-6% improvements in performance in the benchmarks I've run.
For example, with the regexp benchmarks:

Before:
regexp.BenchmarkLiteral   500000       3.26 µs/op
regexp.BenchmarkNotLiteral    100000      13.67 µs/op
regexp.BenchmarkMatchClass    100000      18.72 µs/op
regexp.BenchmarkMatchClass_InRange    100000      20.04 µs/op
regexp.BenchmarkReplaceAll    100000      27.85 µs/op

After:
regexp.BenchmarkLiteral   500000       3.11 µs/op
regexp.BenchmarkNotLiteral    200000      13.29 µs/op
regexp.BenchmarkMatchClass    100000      17.65 µs/op
regexp.BenchmarkMatchClass_InRange    100000      18.49 µs/op
regexp.BenchmarkReplaceAll    100000      26.34 µs/op

R=rsc
CC=golang-dev
https://golang.org/cl/1967047

14 years agocrypto/hmac: make Sum idempotent
Jukka-Pekka Kekkonen [Thu, 26 Aug 2010 17:32:29 +0000 (13:32 -0400)]
crypto/hmac: make Sum idempotent

Fixes #978.

R=rsc
CC=golang-dev
https://golang.org/cl/1967045

14 years agonet/textproto: Handle multi-line responses
Evan Shaw [Thu, 26 Aug 2010 17:32:23 +0000 (13:32 -0400)]
net/textproto: Handle multi-line responses

This is required for FTP and SMTP; maybe others.

R=rsc
CC=golang-dev
https://golang.org/cl/1892052