- 27 Jun, 2002 1 commit
-
-
Tim Peters authored
macros from Zope3. These allow converting some runtime tests into compile-time specialization, and that's going to be more important for work on speeding "lopsided merges".
-
- 25 Jun, 2002 10 commits
-
-
Tim Peters authored
weightedIntersection.
-
Tim Peters authored
intersection and union functions: get the concept of weight entirely out of the internal set iteration protocol. The caller wants values, or doesn't, and that's just a Boolean. This makes for some nice little internal simplifications, but doesn't yet change any semantics.
-
Tim Peters authored
leaving negative weights alone for now.
-
Tim Peters authored
are sets. This just explains what the code actually does; it doesn't make sense to me, so if it does to you feel encouraged to elaborate (in the ZCTextIndex code, we never found a use for the weight outputs of the weighted set ops).
-
Tim Peters authored
-
Tim Peters authored
not sure it's telling the full truth yet.
-
Tim Peters authored
and started repairing obvious errors in their docs. More to come.
-
Tim Peters authored
supplied by the correct BTree modules.
-
Tim Peters authored
the algorithm in a way I believe Jim suggested a few weeks ago (but that I didn't understand then).
-
Tim Peters authored
reason for it not being enabled before.
-
- 24 Jun, 2002 1 commit
-
-
Jeremy Hylton authored
Workaround for bug in Python versions upto and including 2.1.3. If the interpreter was builtin without large file support but the platform had it, os.path.exists() would return false for large files. The fix is to try to open the file first, and decide whether to create a new file based on errno. (Only the two of the last three chunks of the diff affect this behavior.) Also cleanup imports and add some whitespace between arguments to func calls.
-
- 23 Jun, 2002 3 commits
-
-
Tim Peters authored
one bucket.
-
Tim Peters authored
returning X, contradicting the docs and common sense. difference(None, X) continues to return None.
-
Tim Peters authored
Noted that the way difference() treats None doesn't match the docs and is almost certainly wrong.
-
- 22 Jun, 2002 1 commit
-
-
Tim Peters authored
nextBTreeItems() and nextTreeSetItems(): ditto.
-
- 21 Jun, 2002 3 commits
-
-
Tim Peters authored
the recursion (iteration is quite natural here -- it was tail-recursive).
-
Shane Hathaway authored
self, which effectively turned the error into a fatal error. Fixed.
-
Tim Peters authored
code, are bogus when PERSISTENCE is #define'd. Repair them.
-
- 20 Jun, 2002 3 commits
-
-
Jeremy Hylton authored
-
Tim Peters authored
-
Tim Peters authored
a BTree is empty if and only if its firstbucket pointer is NULL, so there's no need to keep checking nonzero inside the loop. Also, the pointers here are all local, so there's no need to incref and decref them -- the apparent necessity was just an artifact of using the bucket assignment macros. So stopped using those macros, and the need for incref/decref operations went away too. PyVar_AssignB(), ASSIGNB(), ASSIGNBC(): Turned out these are no longer used anywhere anymore, so removed them. PER_UNUSE(): New macro to capture the endlessly repeated PER_ALLOW_DEACTIVATION + PER_ACCESSED pair. As the comment says, so sue me <wink>. Bucket_deleteNextBucket(): Documented & simplified.
-
- 19 Jun, 2002 2 commits
-
-
Tim Peters authored
of verifying that BTree invariants are satisfied, raising AssertionError if they're not. Nothing calls this method by magic; it's for debugging.
-
Jeremy Hylton authored
-
- 18 Jun, 2002 6 commits
-
-
Tim Peters authored
some of this code is needed, and to help track down an odd bug Guido is seeing. assert()s won't trigger except in a debug build.
-
Jeremy Hylton authored
-
Jeremy Hylton authored
The old ZEO test suite does not accept description as a keyword arg. Luckily the description is only there to help debug problems; it isn't required for successful completion of the test.
-
Tim Peters authored
PyMalloc(), PyRealloc(): Call malloc() and realloc() directly instead of PyMem_Malloc() and PyMem_Realloc(). If the latter are used, then memory must be freed via PyMem_Free(), but PyMem_Free() isn't called anywhere -- memory is released via raw system free(). It would probably be better to change all uses of free() instead, but that's A Project (well, compared to this ...).
-
Tim Peters authored
is now almost as simple as it's been trying to be <wink>.
-
Tim Peters authored
mean any of no error, an expected index error, or an unexpected error; naturally, callers conflated those. The return value now distinguishes among the cases. BTreeItems_seek(): Use the new form of PreviousBucket().
-
- 17 Jun, 2002 9 commits
-
-
Tim Peters authored
-
Tim Peters authored
purpose wasn't clear, and the few places that bothered to call them seemed to be trying to cater to empty buckets. But empty buckets aren't legitimate in a BTree (or, if they are, lots of BTree code is broken). BTreeItems struct: finished figuring out what's in this, and documented it. BTreeItems_seek(): rewrote and simplified, to avoid use of the now- removed XYZBucketOffset() functions. Repaired places where bucket access time wasn't getting updated. There are still insecurities in its use of PreviousBucket() (for another day). BTreeItems_slice(): now that I know what it is <wink>, create an empty slice in the intended way. NewBTreeItems(): documented its calling sequence, and added code to protect against a NULL highbucket argument. BTree_maxminKey(): no longer calls the XYZBucketOffset() functions.
-
Tim Peters authored
a BTree in an invalid state. Normally, _BTree_set() repairs this before return, but in case of error may not. Now it does.
-
Tim Peters authored
-
Tim Peters authored
an error return leaked references.
-
Tim Peters authored
-
Tim Peters authored
a BTree in an invalid state when called with an empty BTree. I still need to change callers to ensure that the BTree is never left in that invalid state (it can be now).
-
Tim Peters authored
between the Zope2 and Zope3 versions.
-
Tim Peters authored
deletion endcases uncovered by the new degenerate-BTree tests. The degenerate testDeletes() and testEmptyFirstBucketReportedByGuido() are enabled now.
-
- 14 Jun, 2002 1 commit
-
-
Jeremy Hylton authored
-