aboutsummaryrefslogtreecommitdiff
path: root/src/pkg/strings/strings.go
AgeCommit message (Collapse)Author
2009-12-15bytes, strings: add new function FieldsAndrey Mirtchovski
R=rsc, r, phf CC=golang-dev https://golang.org/cl/170046
2009-12-151) Change default gofmt default settings forRobert Griesemer
parsing and printing to new syntax. Use -oldparser to parse the old syntax, use -oldprinter to print the old syntax. 2) Change default gofmt formatting settings to use tabs for indentation only and to use spaces for alignment. This will make the code alignment insensitive to an editor's tabwidth. Use -spaces=false to use tabs for alignment. 3) Manually changed src/exp/parser/parser_test.go so that it doesn't try to parse the parser's source files using the old syntax (they have new syntax now). 4) gofmt -w src misc test/bench 4th set of files. R=rsc CC=golang-dev https://golang.org/cl/180049
2009-12-11bytes, strings: allow -1 in Map to mean "drop this character".Kei Son
xml: drop invalid characters in attribute names when constructing struct field names. R=rsc CC=r https://golang.org/cl/157104
2009-12-02Runes: turn string into []intPeter Froehlich
Split: fixed typo in documentation R=rsc, r, r1 https://golang.org/cl/157170
2009-11-30Typo in comment.Robert Griesemer
Fixes #358. R=rsc CC=r https://golang.org/cl/164043
2009-11-20gofmt -r 'α[β:len(α)] -> α[β:]' -w src/cmd src/pkgRuss Cox
R=r, gri CC=golang-dev https://golang.org/cl/156115
2009-11-18add bytes.IndexByte; common case we can make fast later.Rob Pike
also pick off the special case in strings.Index. don't want strings.IndexByte because the call site will very rarely need to allocate and we can handle the test in the code itself. bytes.IndexByte can avoid a common allocation. R=rsc CC=golang-dev https://golang.org/cl/156091
2009-11-16 An asked-for-in #go-nuts extension to quickly create a repeatedDavid G. Andersen
copy of a string or a byte array. strings.Repeat("-", 50) bytes.Repeat(b, 99) R=rsc https://golang.org/cl/155063
2009-11-09- replaced gofmt expression formatting algorithm withRobert Griesemer
rsc's algorithm - applied gofmt -w misc src - partial CL (last chunk) R=rsc, r http://go/go-review/1024041
2009-11-09remove semis after statements in one-statement statement listsRobert Griesemer
R=rsc, r http://go/go-review/1025029
2009-11-06- fine-tuning of one-line func heuristic (nodes.go)Robert Griesemer
- enabled for function declarations (not just function literals) - applied gofmt -w $GOROOT/src (look for instance at src/pkg/debug/elf/elf.go) R=r, rsc CC=go-dev http://go/go-review/1026006
2009-11-05gofmt-ify strings, templateRobert Griesemer
R=r http://go/go-review/1018064
2009-11-04bytes.SplitAfter and strings.SplitAfterRuss Cox
most common usage is: lines := strings.SplitAfter(text, "\n", 0) R=r http://go/go-review/1018042
2009-10-12fix comment on strings.LastIndex.Russ Cox
add bytes.LastIndex. add strings.Reader. R=r DELTA=59 (56 added, 0 deleted, 3 changed) OCL=35585 CL=35601
2009-10-10change Title to ToTitle for consistency. (the doc comment was already right)Rob Pike
R=rsc DELTA=1 (0 added, 0 deleted, 1 changed) OCL=35572 CL=35572
2009-09-15more "declared and not used".Russ Cox
the last round omitted := range and only checked 1 out of N vars in a multi-var := R=r OCL=34624 CL=34638
2009-09-01casing operations for byte arraysRob Pike
R=rsc DELTA=186 (181 added, 0 deleted, 5 changed) OCL=34203 CL=34203
2009-09-01make ToUpper, ToLower etc. handle unicode properly.Rob Pike
Change their names too. R=rsc DELTA=206 (123 added, 2 deleted, 81 changed) OCL=34170 CL=34194
2009-06-29io.StringBytes -> strings.BytesRuss Cox
io.ByteBuffer -> bytes.Buffer left io.ByteBuffer stub around for now, for protocol compiler. R=r OCL=30861 CL=30872
2009-06-24Change strings.Split, bytes.Split to take a maximum substring count argument.David Symonds
R=rsc APPROVED=r DELTA=131 (39 added, 10 deleted, 82 changed) OCL=30669 CL=30723
2009-06-09Basic HTTP client.Steve Newman
R=rsc APPROVED=rsc DELTA=392 (386 added, 2 deleted, 4 changed) OCL=29963 CL=30107
2009-06-09mv src/lib to src/pkgRob Pike
tests: all.bash passes, gobuild still works, godoc still works. R=rsc OCL=30096 CL=30102