Re: C API []-style access to instance objects

2006-04-27 Thread [EMAIL PROTECTED]
That worked! Thank You! I'd also like to say this group is great at fast accurate responses! Cheers! thanks ~jason -- http://mail.python.org/mailman/listinfo/python-list

Re: C API []-style access to instance objects

2006-04-26 Thread André Malo
* [EMAIL PROTECTED] wrote: > Hi, > > I am having trouble figuring out how to set up an object to be > scriptable through the C API. An example of what I am attempting to > do: > obj = foo.Foo() obj["key"] > Traceback (most recent call last): > File "", line 1, in ? > TypeError: unsu

C API []-style access to instance objects

2006-04-26 Thread [EMAIL PROTECTED]
Hi, I am having trouble figuring out how to set up an object to be scriptable through the C API. An example of what I am attempting to do: >>> obj = foo.Foo() >>> obj["key"] Traceback (most recent call last): File "", line 1, in ? TypeError: unsubscriptable object >>> I've tried defining __ge