> Coming back to this: Why is this done anyway? Can't the new instance of the 
> unicode-subtype just steal the buffer pointer of the already allocated 
> unicode 
> object?

Only if the refcount of the tmp object is 1. But then, yes, it could.
You then also need to change unicode_dealloc, to only optionally release
the pointer (and probably also to not put the object into the freelist
if it doesn't have a str pointer). IOW, no :-)

Regards,
Martin
_______________________________________________
Python-3000 mailing list
Python-3000@python.org
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe: 
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com

Reply via email to