An error occurred fetching the project authors.
  1. 07 Mar, 2011 1 commit
  2. 06 Mar, 2011 1 commit
  3. 04 Mar, 2011 2 commits
    • Rob Pike's avatar
      gob: enable the GobEncoder and GobDecoder interfaces. · 9442e951
      Rob Pike authored
      These allow data items to control their own representation.
      
      For now, the implementation requires that the value passed
      to Encode and Decode must be exactly the type of the
      methods' receiver; it cannot be, for instance, T if the receiver
      is of type *T.  This will be fixed in a later CL.
      
      R=rsc
      CC=golang-dev
      https://golang.org/cl/4235051
      9442e951
    • Rob Pike's avatar
      gob: beginning of support for GobEncoder/GobDecoder interfaces. · c91daefb
      Rob Pike authored
      This allows a data item that can marshal itself to be transmitted by its
      own encoding, enabling some types to be handled that cannot be
      normally, plus providing a way to use gobs on data with unexported
      fields.
      
      In this CL, the necessary methods are protected by leading _, so only
      package gob can use the facilities (in its tests, of course); this
      code is not ready for real use yet.  I could be talked into enabling
      it for experimentation, though.  The main drawback is that the
      methods must be implemented by the actual type passed through,
      not by an indirection from it.  For instance, if *T implements
      GobEncoder, you must send a *T, not a T.  This will be addressed
      in due course.
      
      Also there is improved commentary and a couple of unrelated
      minor bug fixes.
      
      R=rsc
      CC=golang-dev
      https://golang.org/cl/4243056
      c91daefb
  4. 03 Mar, 2011 1 commit
  5. 25 Feb, 2011 1 commit
  6. 23 Feb, 2011 1 commit
    • Rob Pike's avatar
      gob: protect against pure recursive types. · c9b90c9d
      Rob Pike authored
      There are further changes required for things like
      recursive map types.  Recursive struct types work
      but the mechanism needs generalization.  The
      case handled in this CL is pathological since it
      cannot be represented at all by gob, so it should
      be handled separately. (Prior to this CL, encode
      would recur forever.)
      
      R=rsc
      CC=golang-dev
      https://golang.org/cl/4206041
      c9b90c9d
  7. 22 Feb, 2011 1 commit
  8. 14 Feb, 2011 1 commit
    • Rob Pike's avatar
      gob: decode into nil, this time for sure. · 1778f50d
      Rob Pike authored
      Yesterday's change was too simple-minded and failed if an
      interface value was being discarded.  We need to parse the
      data stream and remember any type information that arrives.
      
      Also fix a minor bug when ignoring an interface: toss only what
      we know about, not everything.
      
      R=rsc
      CC=golang-dev
      https://golang.org/cl/4179045
      1778f50d
  9. 28 Jan, 2011 1 commit
  10. 21 Jan, 2011 1 commit
  11. 20 Jan, 2011 1 commit
  12. 12 Jan, 2011 1 commit
  13. 11 Jan, 2011 1 commit
  14. 05 Jan, 2011 1 commit
  15. 31 Oct, 2010 1 commit
    • Rob Pike's avatar
      gob: several fixes. · 7f7cb166
      Rob Pike authored
      1) Be sure to use the eval-time encoder/decoder rather than
      the compile-time decoder.  In a few cases the receiver for
      the compiling encoder was being pickled incorrectly into a
      closure.
      (This is the fix for issue 1238).
      
      2) Get the innermost name right when given a pointer to an
      unnamed type.
      
      3) Use a count to delineate interface values, making it
      possible to ignore values without having a concrete type
      to encode into.  This is a protocol change but only for the
      new feature, so it shouldn't affect anyone.  The old test
      worked because, amazingly, it depended on bug #1.
      
      Fixes #1238.
      
      R=rsc, albert.strasheim
      CC=golang-dev
      https://golang.org/cl/2806041
      7f7cb166
  16. 22 Oct, 2010 3 commits
    • Rob Pike's avatar
      gob: error cleanup 2 · c28fa513
      Rob Pike authored
      Simplify error handling during the compilation phase.
      
      R=rsc
      CC=golang-dev
      https://golang.org/cl/2652042
      c28fa513
    • Rob Pike's avatar
      gobs: error cleanup part 1. · f593b37f
      Rob Pike authored
      Remove err from the encoderState and decoderState types, so we're
      not always copying to and from various copies of the error, and then
      use panic/recover to eliminate lots of error checking.
      
      another pass might take a crack at the same thing for the compilation phase.
      
      R=rsc
      CC=golang-dev
      https://golang.org/cl/2660042
      f593b37f
    • Rob Pike's avatar
      gob: allow exchange of interface values · 5d906469
      Rob Pike authored
      The implemetation describes each value as a string identifying the
      concrete type of the value, followed by the usual encoding of that
      value.  All types to be exchanged as contents of interface values
      must be registered ahead of time with the new Register function.
      Although this would not seem strictly necessary, the linker garbage
      collects unused types so without some mechanism to guarantee
      the type exists in the binary, there could be unpleasant surprises.
      Moreover, the receiver needs a reflect.Type of the value to be
      written in order to be able to save the data. A Register function
      seems necessary.
      
      The implementation may require defining types in the middle of
      of sending a value.  The old code never did this. Therefore there
      has been some refactoring to make the encoder and decoder
      work recursively.
      
      This change changes the internal type IDs. Existing gob archives
      will break with this change.  Apologies for that. If this is a deal
      breaker it should be possible to create a conversion tool.
      
      Error handling is too complicated in this code. A subsequent
      change should clean it up.
      
      R=rsc
      CC=golang-dev
      https://golang.org/cl/2618042
      5d906469
  17. 19 Sep, 2010 1 commit
  18. 12 Sep, 2010 1 commit
  19. 11 Sep, 2010 1 commit
  20. 29 Jun, 2010 1 commit
  21. 28 Jun, 2010 1 commit
  22. 24 Jun, 2010 1 commit
  23. 21 Jun, 2010 1 commit
  24. 20 Jun, 2010 1 commit
  25. 06 May, 2010 1 commit
  26. 05 May, 2010 1 commit
  27. 30 Mar, 2010 1 commit
    • Russ Cox's avatar
      single argument panic · 00f9f0c0
      Russ Cox authored
      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
      https://golang.org/cl/850041
      00f9f0c0
  28. 02 Mar, 2010 1 commit
  29. 29 Dec, 2009 2 commits
  30. 15 Dec, 2009 1 commit
    • Robert Griesemer's avatar
      1) Change default gofmt default settings for · a3d1045f
      Robert Griesemer authored
         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
      https://golang.org/cl/180048
      a3d1045f
  31. 07 Dec, 2009 1 commit
  32. 04 Dec, 2009 1 commit
  33. 01 Dec, 2009 1 commit
  34. 17 Nov, 2009 1 commit
  35. 10 Nov, 2009 1 commit
  36. 09 Nov, 2009 1 commit