On Tue, Apr 26, 2016 at 11:13 AM, Chris Kaynor <ckay...@zindagigames.com> wrote:
> Yah, if you really wanted to make it work properly, you'd need to incref
> the newValue, while decref the oldValue. The incref would not be that
> difficult, but the decref would be more challenging, as you may have to
> also destroy the old object, though that might be possible by casting it
> back to a python object without the incref,. One way or the other, I did
> not exactly spend a ton of time to make it work properly :)

For the decref I'd probably just decrement it and leave it; if it's
zero, the garbage collector will eventually take care of it.
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to