summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2010-03-30time: do not segment time strings by character class.Russ Cox3-173/+212
instead use pure substring matching to find template values. this makes stdZulu unnecessary and allows formats like "20060102 030405" (used in some internet protocols). this makes Parse not handle years < 0000 or > 9999 anymore. that seems like an okay price to pay, trading hypothetical functionality for real functionality. also changed the comments on the Time struct to use the same reference date as the format and parse routines. R=r CC=golang-dev http://codereview.appspot.com/833045
2010-03-30syscall: add IPV6 constantsRuss Cox6-1108/+1255
R=r CC=golang-dev http://codereview.appspot.com/848041
2010-03-30single argument panic on non-darwin and in commentsRuss Cox6-12/+12
R=r CC=golang-dev http://codereview.appspot.com/800042
2010-03-30Gofmt preserves newlines in multiline selector expressions.Risto Jaakko Saarelma4-6/+298
This is for making the fluent interface idiom usable with gofmt. R=gri CC=golang-dev http://codereview.appspot.com/802043 Committer: Robert Griesemer <gri@golang.org>
2010-03-30godoc: don't print package clause in -src command-line mode with filteringRobert Griesemer1-1/+12
R=rsc CC=golang-dev http://codereview.appspot.com/844041
2010-03-30gc: add panic and recover (still unimplemented in runtime)Russ Cox13-25/+173
main semantic change is to enforce single argument to panic. runtime: change to 1-argument panic. use String method on argument if it has one. R=ken2, r CC=golang-dev http://codereview.appspot.com/812043
2010-03-30simplify various code using new map index ruleRuss Cox26-183/+94
R=r CC=golang-dev http://codereview.appspot.com/833044
2010-03-30make: use actual dependency for installRuss Cox1-1/+1
otherwise "make install" runs cp unconditionally R=r CC=golang-dev http://codereview.appspot.com/802044
2010-03-30godefs: fix handling of negative constantsRuss Cox1-2/+8
R=r CC=golang-dev http://codereview.appspot.com/849041
2010-03-30single argument panicRuss Cox25-86/+75
note that sortmain.go has been run through hg gofmt; only the formatting of the day initializers changed. i'm happy to revert that formatting if you'd prefer. stop on error in doc/progs/run R=r CC=golang-dev http://codereview.appspot.com/850041
2010-03-29gc: flush warnings, if anyRuss Cox1-0/+1
R=ken2 CC=golang-dev http://codereview.appspot.com/811042
2010-03-29runtime: Remove unused runtime.write from linux/amd64Christopher Wedgwood1-17/+9
Also minor reformatting. R=rsc CC=golang-dev http://codereview.appspot.com/845041 Committer: Russ Cox <rsc@golang.org>
2010-03-29runtime: run deferred calls at GoexitRuss Cox6-52/+110
baby step toward panic+recover. Fixes issue 349. R=r CC=golang-dev http://codereview.appspot.com/825043
2010-03-29go/printer: fix a commentRobert Griesemer1-1/+1
R=rsc CC=golang-dev http://codereview.appspot.com/826042
2010-03-29godoc: support for filtering of command-line output in -src modeRobert Griesemer4-67/+111
+ various minor cleanups Usage: godoc -src math Sin R=rsc CC=golang-dev http://codereview.appspot.com/791041
2010-03-29Flags: add user-defined flag types. The change is really no code; it's just ↵Rob Pike2-45/+64
publishing the set() method and add() functions. But we rename add() to Var() for consistency. Also rename FlagValue to Value for simplicity. Also, delete the check for multiple settings for a flag. This makes it possible to define a flag that collects values, such as into a slice of strings. type flagVar []string func (f *flagVar) String() string { return fmt.Sprint(v) } func (f *flagVar) Set(value string) bool { if v == nil { v = make(flagVar, 1) } else { nv := make(flagVar, len(v)+1) copy(nv, v) v = nv } v[len(v)-1] = value return true } var v flagVar func main() { flag.Var(&v, "testV", "multiple values build []string") flag.Parse() fmt.Printf("v = %v\n", v) } R=rsc CC=golang-dev http://codereview.appspot.com/842041
2010-03-29runtime: a couple more memory stats.Russ Cox7-1/+14
now runtime.MemStats.Sys really is the sum of all the other Sys fields. R=r CC=golang-dev http://codereview.appspot.com/843041
2010-03-29gc: bug265Russ Cox1-5/+20
Fixes issue 700. R=ken2 CC=golang-dev http://codereview.appspot.com/839041
2010-03-29go/ast: generalized ast filteringRobert Griesemer2-26/+129
R=rsc CC=golang-dev http://codereview.appspot.com/788041
2010-03-29strings.FIelds: slight simplification.Rob Pike1-4/+5
R=rsc CC=golang-dev http://codereview.appspot.com/833042
2010-03-29fix buildRuss Cox1-2/+2
R=gri CC=golang-dev http://codereview.appspot.com/837041
2010-03-29runtime: more malloc statisticsRuss Cox8-33/+145
expvar: default publishings for cmdline, memstats godoc: import expvar R=r CC=golang-dev http://codereview.appspot.com/815041
2010-03-29strconv.Unquote could wrongly return a nil error on error.Roger Peppe1-1/+1
R=rsc, gri CC=golang-dev http://codereview.appspot.com/773041 Committer: Robert Griesemer <gri@golang.org>
2010-03-29comment typosAndrew Gerrand1-3/+3
Fixes issue 698. Fixes issue 699. R=rsc CC=golang-dev http://codereview.appspot.com/824041
2010-03-29comment typo in crypto/rsa/rsa.goAndrew Gerrand1-1/+1
R=rsc CC=golang-dev http://codereview.appspot.com/823041
2010-03-29http: add HandleFunc as shortcut to Handle(path, HandlerFunc(func))Andrew Gerrand1-0/+11
R=rsc CC=golang-dev http://codereview.appspot.com/763042
2010-03-27xml: use io.ReadByter in place of local readByterRaif S. Naffah1-6/+2
R=cemeyer, rsc CC=golang-dev http://codereview.appspot.com/809041 Committer: Russ Cox <rsc@golang.org>
2010-03-26arm: fix buildDean Prichard1-5/+4
R=rsc CC=golang-dev http://codereview.appspot.com/800041 Committer: Russ Cox <rsc@golang.org>
2010-03-26gc: allow taking address of out parametersRuss Cox5-11/+95
Fixes issue 186. R=ken2 CC=golang-dev http://codereview.appspot.com/793041
2010-03-26fix buildRobert Griesemer1-1/+1
R=r CC=golang-dev http://codereview.appspot.com/790041
2010-03-26regexp: don't return non-nil *Regexp if there is an error.Rob Pike2-0/+6
R=gri CC=golang-dev http://codereview.appspot.com/787041
2010-03-26pprof: dump extra heap information at end of heap profileRuss Cox1-0/+24
R=r CC=golang-dev http://codereview.appspot.com/786041
2010-03-26fix buildRuss Cox1-1/+1
TBR=r CC=golang-dev http://codereview.appspot.com/785041
2010-03-26godoc: export pprof debug informationRuss Cox1-0/+1
R=gri CC=golang-dev http://codereview.appspot.com/784041
2010-03-26prof: install gopprof tooRuss Cox2-1/+4725
This is a modified version of the open source pprof from code.google.com/p/google-perftools. That version is likely to catch up to this one, but it's still useful to ship our own copy since we only need the one script from that project, not all the C++ libraries. R=r CC=golang-dev http://codereview.appspot.com/783041
2010-03-26runtime: run all finalizers in a single goroutine.Russ Cox7-121/+152
eliminate second pass of mark+sweep by scanning finalizer table specially. R=r CC=golang-dev http://codereview.appspot.com/782041
2010-03-26math: add J1, Y1, Jn and Yn (Bessel functions)Charles L. Dorian5-42/+970
Also amend j0.go (variable name conflict, small corrections). R=rsc CC=golang-dev http://codereview.appspot.com/769041 Committer: Russ Cox <rsc@golang.org>
2010-03-26syscall: Create syscall_bsd.go for code used by Darwin and other *BSDsGiles Lean6-934/+489
In this change I'd like to combine the common code that is present in syscall_darwin.go and syscall_freebsd.go. I have three reasons for wanting to do this now: 1. reducing code duplication is nearly always good :-) 2. the duplication will get worse if I duplicate this code a third time for the NetBSD port I'm working on, which I need to do almost immediately 3. by making this change all in one lump and ignoring any commonality with the syscall_linux*.go files the diff is long but, I think, readable In future it may be possible to cherry pick functions that also apply to Linux and put them in (say) syscall_unix.go, and of course some functions may diverge in future and have to move out to OS or architecture specific files, but today I want just the low hanging fruit. Tested and passed on: Darwin (Snow Leopard, 10.6): amd64 and 386 FreeBSD (8.0-RELEASE): 386 only(*) (*) All my virtualisation software has stopped playing nice with FreeBSD for the moment, so I don't have facilities to test the amd64 port. As the OS X port is OK and the diff looks all right to my eyes I shall keep my fingers crossed. If someone with a FreeBSD/amd64 system cares to test and report I would be appreciative. 2010-03-27 update: I have replaced my virtualisation software, and have working FreeBSD/i386 and FreeBSD/amd64 virtual machines again. As I hoped (and expected -- programmers are optimists :-) the code built and passed all but the two currently known to fail tests on FreeBSD/amd64. I rechecked FreeBSD/i386 too: same results. R=rsc CC=golang-dev http://codereview.appspot.com/751041 Committer: Russ Cox <rsc@golang.org>
2010-03-26bytes, strings: IndexOfAnyRobert Griesemer5-28/+102
+ first use in go/doc R=r CC=golang-dev http://codereview.appspot.com/781041
2010-03-26fix spelling of alignRob Pike7-14/+14
R=rsc CC=golang-dev http://codereview.appspot.com/778041
2010-03-26xgb: fix request length and request size.Firmansyah Adiputra2-15/+18
R=nigeltao_golang, rsc CC=golang-dev http://codereview.appspot.com/759041 Committer: Russ Cox <rsc@golang.org>
2010-03-25godoc: don't convert multi-line functions into one-liners by defaultRobert Griesemer9-64/+150
- new heuristic: if both the opening { and closing } braces are on the same line, and the function body doesn't contain comments or is other- wise too long (e.g. signature too long), it is formatted as a one-line function - related cleanups along the way - gofmt -w src misc led to no additional changes as expected R=rsc, rsc1 CC=golang-dev, ken2, r http://codereview.appspot.com/758041
2010-03-25make alignment rules match 8g, just like 6c matches 6g.Russ Cox1-2/+4
R=ken2 CC=golang-dev http://codereview.appspot.com/760042
2010-03-25gc: more syntax errorsRuss Cox1-10/+16
R=r CC=golang-dev http://codereview.appspot.com/731041
2010-03-25Add strconv.Atob, Btoa.Rob Pike5-17/+94
Fixes issue 639 R=rsc CC=golang-dev http://codereview.appspot.com/755041
2010-03-25Support #pragma dynexport on OS X.Ian Lance Taylor1-20/+108
R=rsc CC=golang-dev http://codereview.appspot.com/733041
2010-03-24syscall: Implement SetsockoptStringChristopher Wedgwood3-0/+10
R=rsc, r CC=golang-dev http://codereview.appspot.com/739042 Committer: Russ Cox <rsc@golang.org>
2010-03-24syscall: bring generated files zsyscall_darwin_*.goGiles Lean2-12/+12
up to date. No functional change, but when these files are regenerated they change, leading to noisy diffs when working in the syscall package. R=golang-dev, rsc CC=golang-dev http://codereview.appspot.com/705043 Committer: Russ Cox <rsc@golang.org>
2010-03-24runtime: fix mingw build, implement missing destroylock()Alex Brainman1-0/+5
R=golang-dev, rsc CC=golang-dev http://codereview.appspot.com/747041 Committer: Russ Cox <rsc@golang.org>
2010-03-24depricate paniclnKen Thompson6-13/+4
R=rsc CC=golang-dev http://codereview.appspot.com/743041