summaryrefslogtreecommitdiff
path: root/src/pkg/gob/codec_test.go
AgeCommit message (Collapse)AuthorFilesLines
2011-04-26Imported Upstream version 2011.04.13upstream/2011.04.13Ondřej Surý1-25/+32
2011-04-20Imported Upstream version 2011.03.07.1upstream/2011.03.07.1Ondřej Surý1-12/+26
2011-02-14Imported Upstream version 2011-02-01.1upstream/2011-02-01.1Ondřej Surý1-64/+50
2011-01-17Imported Upstream version 2011.01.12upstream/2011.01.12Ondřej Surý1-242/+530
2010-06-28gob: add DecodeValue and EncodeValueRob Pike1-1/+1
R=rsc CC=golang-dev http://codereview.appspot.com/1698045
2010-06-28gob: allow transmission of things other than structs at the top level.Rob Pike1-9/+10
also fix a bug handling nil maps: before, would needlessly send empty map R=rsc CC=golang-dev http://codereview.appspot.com/1739043
2010-06-24gob: add support for complex numbersRob Pike1-1/+62
R=rsc CC=golang-dev http://codereview.appspot.com/1708048
2010-06-20reflect: add Kind, remove Int8Type, Int8Value, etc.Russ Cox1-4/+4
update other code to match. R=r CC=golang-dev http://codereview.appspot.com/1680044
2010-05-06gob: add test for indirect maps, slices, arrays.Rob Pike1-0/+67
fix a bug in the handling of indirect maps. R=rsc CC=golang-dev http://codereview.appspot.com/1132042
2010-05-05gob: add support for maps.Rob Pike1-0/+6
Because maps are mostly a hidden type, they must be implemented using reflection values and will not be as efficient as arrays and slices. R=rsc CC=golang-dev http://codereview.appspot.com/1127041
2010-03-02gofmt: experiment: align values in map composites where possibleRobert Griesemer1-8/+8
- gofmt -w src misc - looking for feedback R=rsc, r CC=golang-dev http://codereview.appspot.com/223076
2010-02-25strings: delete Runes, BytesRuss Cox1-3/+3
gofmt -w -r 'strings.Bytes(a) -> []byte(a)' src/cmd src/pkg test/bench gofmt -w -r 'strings.Runes(a) -> []int(a)' src/cmd src/pkg test/bench delete unused imports R=r CC=golang-dev http://codereview.appspot.com/224062
2009-12-151) Change default gofmt default settings forRobert Griesemer1-395/+395
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 3rd set of files. R=rsc CC=golang-dev http://codereview.appspot.com/180048
2009-11-16Rework gobs to fix bad bug related to sharing of id's between encoder and ↵Rob Pike1-45/+57
decoder side. Fix is to move all decoder state into the decoder object. Fixes issue 215. R=rsc CC=golang-dev http://codereview.appspot.com/155077
2009-11-09 - replaced gofmt expression formatting algorithm withRobert Griesemer1-7/+7
rsc's algorithm - applied gofmt -w misc src - partial CL (remaining files in other CLs) R=rsc, r http://go/go-review/1026036
2009-11-09remove semis after statements in one-statement statement listsRobert Griesemer1-69/+69
R=rsc, r http://go/go-review/1025029
2009-11-06- application of gofmt with one-line composite literal structs enabledRobert Griesemer1-48/+16
- this CL is dependent on CL 1025008 R=r, rsc http://go/go-review/1025009
2009-11-05gofmt-ify gobRobert Griesemer1-210/+289
(the one-line struct types used in composite literals will become one line again in another cleanup round; don't worry about them now) R=r http://go/go-review/1016056
2009-09-16rename bytes.Buffer.Data() to bytes.Buffer.Bytes()Rob Pike1-34/+34
R=rsc DELTA=152 (6 added, 0 deleted, 146 changed) OCL=34695 CL=34701
2009-09-15more "declared and not used".Russ Cox1-1/+1
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-14fix "declared and not used" errors in non-test code.Russ Cox1-4/+0
R=r DELTA=112 (6 added, 57 deleted, 49 changed) OCL=34610 CL=34610
2009-08-26fix codec test bug - uint -> uint8Russ Cox1-3/+3
R=r OCL=33913 CL=33913
2009-08-12convert gob to whole-package compilation.Russ Cox1-1/+0
had to reorder some init code. R=r DELTA=136 (15 added, 110 deleted, 11 changed) OCL=33071 CL=33102
2009-07-29handle unsupported types safely.Rob Pike1-8/+25
R=rsc DELTA=154 (71 added, 6 deleted, 77 changed) OCL=32483 CL=32492
2009-07-28change the encoding of uints to simplify overflow checking and to make themRob Pike1-46/+44
easier and faster to read. they are now either a one-byte value or a n-byte value preceded by a byte holding -n. R=rsc DELTA=150 (45 added, 7 deleted, 98 changed) OCL=32381 CL=32387
2009-07-28- clean up code creating keys for type mapsRob Pike1-29/+193
- derive int, uint, float, uintptr decoders based on their size - add overflow checks in decode R=rsc DELTA=407 (281 added, 44 deleted, 82 changed) OCL=32286 CL=32290
2009-07-27clean up for public use: make some stuff private, add doc comments.Rob Pike1-7/+8
R=rsc DELTA=298 (202 added, 0 deleted, 96 changed) OCL=32006 CL=32224
2009-07-17ignore missing structsRob Pike1-1/+6
R=rsc DELTA=113 (74 added, 14 deleted, 25 changed) OCL=31776 CL=31776
2009-07-16- allow wire type and receive type to differ.Rob Pike1-8/+74
- still TODO: ignoring struct fields. R=rsc DELTA=309 (240 added, 2 deleted, 67 changed) OCL=31750 CL=31750
2009-07-15make the low-level encoder and decoder private and have them access ↵Rob Pike1-71/+71
byte.Buffers rather than io.Readers and io.Writers. change the Encoder/Decoder protocol so that each message is preceded by its length in bytes. R=rsc DELTA=468 (119 added, 23 deleted, 326 changed) OCL=31700 CL=31702
2009-07-09store ids rather than Types in the structs so they can be encoded.Rob Pike1-1/+24
change Type to gobType. fix some bugs around recursive structures. lots of cleanup. add the first cut at a type encoder. R=rsc DELTA=400 (287 added, 11 deleted, 102 changed) OCL=31401 CL=31406
2009-07-02slicesRob Pike1-1/+3
R=rsc DELTA=59 (44 added, 13 deleted, 2 changed) OCL=31105 CL=31105
2009-07-02indirection on array elements.Rob Pike1-0/+4
R=rsc DELTA=57 (34 added, 10 deleted, 13 changed) OCL=31098 CL=31101
2009-07-02arrays, not slices, and only with non-pointer elements.Rob Pike1-77/+36
(actually slices encode but do not decode yet) R=rsc DELTA=221 (82 added, 65 deleted, 74 changed) OCL=31095 CL=31095
2009-07-02encode and decode for nested structures.Rob Pike1-0/+5
fix a bug in delta encoding: only update the delta-base if something is marshaled. R=rsc DELTA=154 (94 added, 56 deleted, 4 changed) OCL=31069 CL=31071
2009-07-02encoders and decoders for string, []uint8Rob Pike1-12/+73
R=rsc DELTA=165 (145 added, 6 deleted, 14 changed) OCL=31051 CL=31056
2009-07-02now that we have a separate indirection test, simplify the scalar tests.Rob Pike1-497/+81
R=rsc DELTA=562 (8 added, 424 deleted, 130 changed) OCL=31039 CL=31045
2009-07-02fix bug in decoders: got indirection wrong when allocation not required.Rob Pike1-3/+83
write indirection test. next step: cut down scalar tests since indirection is centralized. R=rsc DELTA=114 (83 added, 3 deleted, 28 changed) OCL=31020 CL=31037
2009-07-01move dereference code out of the ops and into the interpreter loops.Rob Pike1-84/+95
R=rsc DELTA=574 (40 added, 149 deleted, 385 changed) OCL=31017 CL=31019
2009-07-01Encode and decode engines for gobs.Rob Pike1-51/+93
R=rsc DELTA=468 (292 added, 18 deleted, 158 changed) OCL=31008 CL=31012
2009-06-30scalar decodersRob Pike1-43/+480
R=rsc DELTA=897 (728 added, 14 deleted, 155 changed) OCL=30955 CL=30955
2009-06-30pass the state to the encoders and decoders so error handling can be ↵Rob Pike1-17/+25
centralized. R=rsc DELTA=172 (40 added, 6 deleted, 126 changed) OCL=30941 CL=30944
2009-06-30encoders for booleans and numbers.Rob Pike1-0/+352
R=rsc DELTA=610 (597 added, 5 deleted, 8 changed) OCL=30934 CL=30939
2009-06-29io.StringBytes -> strings.BytesRuss Cox1-4/+3
io.ByteBuffer -> bytes.Buffer left io.ByteBuffer stub around for now, for protocol compiler. R=r OCL=30861 CL=30872
2009-06-29integer encode/decodeRob Pike1-0/+98
R=rsc DELTA=185 (175 added, 10 deleted, 0 changed) OCL=30863 CL=30871