[ZODB-Dev] RE: B-Tree API - again!

Christian Reis kiko@async.com.br
Fri, 6 Dec 2002 15:21:27 -0200


On Fri, Dec 06, 2002 at 11:55:59AM -0500, Jeremy Hylton wrote:
>   ML> Why is it that OOBTree doesn't have a __delitem__ but "del
>   ML> tree[x]" still works!
> 
> I figure it must have something to do with ExtensionClass.

Apparently if delitem is not defined setitem is called with NULL for
its value, as I wrote in the previous analysis. At least that's what
seems to be happening for the BTreeType extensionclass, which sets the
relevant methods in the tp_as_mapping structure member.

Take care,
--
Christian Reis, Senior Engineer, Async Open Source, Brazil.
http://async.com.br/~kiko/ | [+55 16] 261 2331 | NMFL