Russ Cox
6e2ae0a12c
runtime/pprof: support OS X CPU profiling
...
Work around profiling kernel bug with signal masks.
Still broken on 64-bit Snow Leopard kernel,
but I think we can ignore that one and let people
upgrade to Lion.
Add new trivial tools addr2line and objdump to take
the place of the GNU tools of the same name, since
those are not installed on OS X.
Adapt pprof to invoke 'go tool addr2line' and
'go tool objdump' if the system tools do not exist.
Clean up disassembly of base register on amd64.
Fixes #2008 .
R=golang-dev, bradfitz, mikioh.mikioh, r, iant
CC=golang-dev
https://golang.org/cl/5697066
2012-02-28 16:18:24 -05:00
Rémy Oudompheng
c10f50859e
all: remove various unused unexported functions and constants.
...
R=golang-dev, minux.ma, rsc
CC=golang-dev, remy
https://golang.org/cl/5702050
2012-02-28 21:48:03 +01:00
Rob Pike
250fa82122
net/rpc: API changes, all documentation
...
except for hiding one type that is only used internally.
Fixes #2944 .
R=golang-dev, rsc, kevlar
CC=golang-dev
https://golang.org/cl/5707044
2012-02-29 07:34:28 +11:00
Shenghou Ma
26daf6a03f
cmd/dist: force line-buffering stdout/stderr on Unix
...
If stdout and stderr are indeed the same file (not a tty), which is
often the case, fully-buffered stdout will make it harder to see
progresses, for example, ./make.bash 2>&1 | tee log
R=r, rsc
CC=golang-dev
https://golang.org/cl/5700070
2012-02-29 02:22:28 +08:00
Mikkel Krautz
fb1a5fcacf
crypto/tls: force OS X target version to 10.6 for API compatibility
...
This is a band-aid until we can use weak imports with cgo.
Fixes #3131 .
R=minux.ma, rsc
CC=golang-dev
https://golang.org/cl/5700083
2012-02-28 11:34:48 -05:00
Shenghou Ma
e0aa36147d
encoding/gob: fix "// +build" comment for debug.go
...
R=golang-dev, rsc, adg, r, r
CC=golang-dev
https://golang.org/cl/5693060
2012-02-28 13:39:42 +08:00
Robert Griesemer
e952e241ae
gotype: provide -comments flag
...
When debugging ASTs, it's useful to also
see the comments on occasion. Usage:
gotype -ast -comments file.go
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5703043
2012-02-27 21:35:26 -08:00
Andrew Gerrand
64bc38eb85
godoc: add Examples link to top-level index
...
R=golang-dev
CC=golang-dev
https://golang.org/cl/5702043
2012-02-28 16:05:12 +11:00
Rob Pike
26c2443d80
text/template: add example showing use of custom function
...
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/5694100
2012-02-28 15:50:41 +11:00
Rob Pike
180541b2b1
text/template: fix redefinition bugs
...
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/5696087
2012-02-28 14:23:57 +11:00
Robert Griesemer
69015b6fc4
test: bug424: wrong embedded method called
...
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5695083
2012-02-27 18:52:40 -08:00
Rob Pike
7201b0c27c
tutorial: delete
...
Instead we'll point people at the Tour and beef up code.html.
Fixes #3107 .
R=golang-dev, bradfitz, r, adg
CC=golang-dev
https://golang.org/cl/5697077
2012-02-28 13:35:58 +11:00
Mikio Hara
d9c5626047
net: no panic on placeholders for netbsd
...
Perhaps it might be better than panic.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5701064
2012-02-28 10:58:01 +09:00
David Symonds
9dd746c4cb
encoding/json: drop MarshalForHTML; gofix calls to Marshal.
...
I've elected to omit escaping the output of Marshalers for now.
I haven't thought through the implications of that;
I suspect that double escaping might be the undoing of that idea.
Fixes #3127 .
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5694098
2012-02-28 11:41:16 +11:00
Benny Siegert
740d503866
net: add stubs for NetBSD
...
This fixes the build of package net for GOOS=NetBSD.
Of course, a real implementation would be even better.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5693065
2012-02-28 11:28:10 +11:00
Benny Siegert
8c7b832ad5
os: fix NetBSD build
...
os.fileStat.Sys is no longer exported.
R=golang-dev, m4dh4tt3r, r
CC=golang-dev
https://golang.org/cl/5696074
2012-02-28 11:26:01 +11:00
Andrew Gerrand
2f4e5f79a6
gobuilder: send commit time in RFC3339 format
...
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5701063
2012-02-28 11:21:56 +11:00
Brad Fitzpatrick
fa33fdbc7d
encoding/binary: better example
...
leave that joke to Java.
R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/5695080
2012-02-28 10:15:23 +11:00
Andrew Gerrand
ce51e10749
archive/zip: use encoding/binary again, add readBuf helper
...
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5699097
2012-02-28 09:41:30 +11:00
Stefan Nilsson
4fae9f7943
doc/go1: fix broken link
...
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/5695072
2012-02-28 09:22:55 +11:00
Anthony Martin
eafe86c2df
go/printer: fix printing of variadic function calls
...
Fixes #3130 .
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5697062
2012-02-27 13:56:43 -08:00
Rob Pike
5573fa3bc5
cmd/go: mention examples in docs for -test.run
...
Missed in my last round. These things sure appear
in a lot of places.
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5699096
2012-02-28 08:55:25 +11:00
Rob Pike
ec15046a8d
cmd/go: drop -example, apply -run to examples
...
Once more, with feeling.
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5698080
2012-02-28 08:33:06 +11:00
Yissakhar Z. Beck
1f5fde0915
misc/bash: Completion for go tool.
...
This covers most of the tool's functionality. At some point,
support should probably be added for testflags and the various go
tools.
R=golang-dev, bradfitz, kyle, minux.ma
CC=golang-dev
https://golang.org/cl/5646066
2012-02-28 07:41:49 +11:00
Brad Fitzpatrick
9aff05e362
A+C: add Yissakhar Z. Beck (Individual CLA)
...
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5698079
2012-02-28 07:40:44 +11:00
Robert Griesemer
b495e5c538
strings: make Count example show results
...
Thanks to dr.volker.dobler for tracking this down.
Filed a long-term issue (3142) which may eventually
resolve this problem w/o the need for a manual fix.
R=iant
CC=golang-dev
https://golang.org/cl/5698078
2012-02-27 12:22:10 -08:00
Robert Griesemer
ab169c6e3f
godoc: don't show directories w/o packages in flat dir mode
...
The main change is simple: Both the Directory and DirEntry
struct have an extra field 'HasPkg' indicating whether the
directory contains any package files. The remaining changes
are more comments and adjustments to the template files.
Fixes #3121 .
R=golang-dev, bradfitz, sameer
CC=golang-dev
https://golang.org/cl/5699072
2012-02-27 11:18:00 -08:00
Anthony Martin
0706d00cb8
go/printer: fix test for new import path restrictions
...
Import paths with spaces are now invalid.
The builders would've caught this if they were running
the long tests. I've removed the check for short tests
in this package since the current tests are fast enough
already.
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5694082
2012-02-27 10:01:45 -08:00
Shenghou Ma
56ae9032b2
cmd/go: test -i should not disable -c
...
Fixes #3104 .
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/5699088
2012-02-27 12:33:14 -05:00
Andrew Gerrand
eb825b58cc
archive/zip: use smarter putUintXX functions to hide offsets
...
R=bradfitz, r, dsymonds, kyle
CC=golang-dev
https://golang.org/cl/5701055
2012-02-27 17:37:59 +11:00
Andrew Gerrand
228f44a1f5
archive/zip: stop using encoding/binary
...
R=golang-dev, r, bradfitz
CC=golang-dev
https://golang.org/cl/5694085
2012-02-27 16:29:22 +11:00
Rob Pike
28668c3a28
cmd/go: run examples even if -run is set if -example is also set
...
Allows one to disable everything but the example being debugged.
This time for sure.
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5700079
2012-02-27 16:23:22 +11:00
Andrew Gerrand
2d6a6ed9fc
misc/dashboard: fix bug in UI template
...
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/5700078
2012-02-27 16:18:58 +11:00
Andrew Gerrand
8421390cb9
misc/dashboard: record install counts for external packages
...
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5699082
2012-02-27 15:25:41 +11:00
Rob Pike
cc7e11c91e
doc/go1: mention that regexp has changed
...
Also restore alphabetical order.
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5701053
2012-02-27 14:34:16 +11:00
Andrew Gerrand
e10dc82ce0
doc: instruct freebsd/linux users to rm the old version first
...
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5701052
2012-02-27 14:16:56 +11:00
Rob Pike
5876b4eb28
testing: add -test.example flag to control execution of examples
...
Also, don't run examples if -test.run is set.
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/5697069
2012-02-27 12:49:10 +11:00
Alex Brainman
c7482b9196
os: implement sameFile on windows
...
Fixes #2511 .
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/5687072
2012-02-27 12:29:33 +11:00
Mikkel Krautz
e4db4e9b58
crypto/x509: fix typo in Verify documentation
...
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5695070
2012-02-27 11:49:06 +11:00
Mike Rosset
4762e9d98c
html/template: use correct method signature, in introduction example.
...
R=golang-dev, nigeltao
CC=golang-dev
https://golang.org/cl/5695067
2012-02-27 11:31:38 +11:00
Andrew Gerrand
cd1a2f7e74
doc: move wiki tutorial into articles directory, rmdir doc/codelab
...
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5701050
2012-02-27 11:25:43 +11:00
Rob Pike
b49dcb9d37
cmd/go: explain x... vs. x/... in help importpath
...
Fixes #3110 .
R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5696083
2012-02-27 09:51:58 +11:00
Brad Fitzpatrick
761f946617
net/http/cgi: add an empty response test
...
New test for http://code.google.com/p/go/source/detail?r=a73ba18
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/5701046
2012-02-26 14:46:22 -08:00
Rob Pike
68c7e8a2f4
doc/go1: add justification discussions to major changes
...
Fixes #3086 .
R=golang-dev, gri, r, kevlar
CC=golang-dev
https://golang.org/cl/5700067
2012-02-27 07:31:34 +11:00
Rob Pike
d781603931
time: add a comment about how to use the Duration constants
...
R=golang-dev, bradfitz, r, dsymonds
CC=golang-dev
https://golang.org/cl/5696078
2012-02-26 22:24:51 +11:00
Shenghou Ma
f7ad1834ea
doc/install: fix FreeBSD/Linux install command
...
R=adg, golang-dev, go.peter.90, rsc
CC=golang-dev
https://golang.org/cl/5700062
2012-02-26 01:40:29 +08:00
Shenghou Ma
bdca78e1a7
cmd/yacc/units.y: update comment, give better error messages when $GOROOT not set
...
R=r, golang-dev
CC=golang-dev
https://golang.org/cl/5698062
2012-02-26 01:36:26 +08:00
Mike Rosset
4af3dda41b
doc: update Go1 release notes to use correct WalkFunc error signature.
...
filepath's WalkFunc handler now uses errors package, and not
os.Error
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5696067
2012-02-24 22:17:21 -08:00
Robert Griesemer
5c7799f108
go: fix help text documenting example functions
...
R=adg, r
CC=golang-dev
https://golang.org/cl/5695062
2012-02-24 15:42:25 -08:00
Rob Pike
e303eeb75b
go/test/chan1.go: fix typo
...
Found by Lucio De Re
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5694071
2012-02-25 08:47:04 +11:00