This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author belopolsky
Recipients alexandre.vassalotti, belopolsky, lemburg, mark.dickinson, pitrou
Date 2010-06-28.17:20:50
SpamBayes Score 0.0014518294
Marked as misclassified No
Message-id <1277745654.55.0.77581115264.issue5180@psf.upfronthosting.co.za>
In-reply-to
Content
I am attaching a patch which focuses on fixing _pickle behavior.   I opened a separate issue9102 to deal with pybench specific problems.

Marc-Andre,

I am reassigning this issue to myself and assigning issue9102 to you.  I hope you don't mind.

My patch attempts to emulate 2.x PyInstance_NewRaw with a call to tp_alloc.  I considered using tp_new, but although __new__ is not special for classic classes, there is nothing to prevent users to define __new__ in their classic classes or add __new__ when they port these classes to 3.x.  (BTW, I wonder what 2to3 does if classic class has __new__ defined.)  This is slightly unorthodox use of tp_alloc, so I will follow up with a question on python-dev.
History
Date User Action Args
2010-06-28 17:20:55belopolskysetrecipients: + belopolsky, lemburg, mark.dickinson, pitrou, alexandre.vassalotti
2010-06-28 17:20:54belopolskysetmessageid: <1277745654.55.0.77581115264.issue5180@psf.upfronthosting.co.za>
2010-06-28 17:20:53belopolskylinkissue5180 messages
2010-06-28 17:20:51belopolskycreate