- 28 Ock, 2003 40 kayıt (commit)
-
-
Barry Warsaw yazdı
so merge from the bsddb-bsddb3-schizo-branch back to the trunk.
-
Tim Peters yazdı
-
Tim Peters yazdı
-
Tim Peters yazdı
was used before string-escape codecs were added to the core.)
-
Guido van Rossum yazdı
checks to save_reduce(), which can also be called from a subclass.) Also tweaked some more comments.
-
Tim Peters yazdı
-
Tim Peters yazdı
they're easier to read this way.
-
Guido van Rossum yazdı
-
Tim Peters yazdı
of the opcode character instead (but stripping the quotes). Added a proto 2 test section for the canonical recursive-tuple case. Note that since pickle's save_tuple() takes different paths depending on tuple length now, beefier tests are really needed (but not in pickletools); the "short tuple" case tried here was actually broken yesterday, and it's subtle stuff so needs to be tested.
-
Guido van Rossum yazdı
be one of 0, 1 or 2). I should note that the previous checkin also added NEWOBJ support to the unpickler -- but there's nothing yet that generates this.
-
Guido van Rossum yazdı
type 'object'. Also minor docstring tweakage, and rearranged a few lines in save().
-
Guido van Rossum yazdı
memoized in text mode. Fixed some variable names in the disassembler doctest.
-
Guido van Rossum yazdı
-
Fred Drake yazdı
Martin's integration changes).
-
Tim Peters yazdı
control flow had to be simplified.
-
Tim Peters yazdı
incorrect for recursive tuples. Tried to repair; seems to work OK, but there are no checked-in tests for this yet.
-
Tim Peters yazdı
-
Tim Peters yazdı
Also moved the proto2 opcode descriptors into the sections they fit (like TUPLE{1,2,3} in the group of tuple-building opcodes; etc).
-
Guido van Rossum yazdı
NEWFALSE and NEWTRUE.
-
Guido van Rossum yazdı
would be that the tuple is reversed on unpickling, and we should catch that. :-) Goodnight -- that's it for toniht!
-
Guido van Rossum yazdı
Also moved the special case for empty tuples from save() to save_tuple().
-
Guido van Rossum yazdı
change in meaning.
-
Tim Peters yazdı
of my recent XXX comment, taking a (what appears to be vanishingly small) chance and calling self.memoize() instead.
-
Guido van Rossum yazdı
-
Tim Peters yazdı
-
Tim Peters yazdı
-
Guido van Rossum yazdı
marshal.loads() beats struct.unpack()! Possibly because the latter creates a one-tuple. :-(
-
Guido van Rossum yazdı
40% faster than marshal.dumps(x)[1:]! (That's not counting the module attribute lookups, which can be avoided in either case.)
-
Tim Peters yazdı
created by recursive tuples.
-
Tim Peters yazdı
-
Tim Peters yazdı
-
Tim Peters yazdı
iteritems() instead of materializing a (possibly giant) list of the items.
-
Tim Peters yazdı
The code is much easier to follow now, and I bet it's faster too.
-
Tim Peters yazdı
-
Tim Peters yazdı
-
Tim Peters yazdı
make the bin-vs-not-bin order consistent with what other routines try to do (they almost all handle the bin case first).
-
Tim Peters yazdı
some notion of low-level efficiency. Undid that, but left one routine alone: save_inst() claims it has a reason for not using memoize(). I don't understand that comment, so added an XXX comment there.
-
Tim Peters yazdı
belongs. This is a much smaller change than it may appear: the bulk of the function merely got unindented by one level.
-
Tim Peters yazdı
-
Tim Peters yazdı
-