[issue17722] 'round' function doesn't honour a descriptor __round__

2013-04-13 Thread Benjamin Peterson
Benjamin Peterson added the comment: In this case, I had almost finished a patch as I was talking with you on IRC, but I had to go play in a show for 3 hours. -- ___ Python tracker

[issue17722] 'round' function doesn't honour a descriptor __round__

2013-04-13 Thread Mark Dickinson
Mark Dickinson added the comment: No problem. Do you usually keep patches in your WC? -- ___ Python tracker ___ ___ Python-bugs-list

[issue17722] 'round' function doesn't honour a descriptor __round__

2013-04-13 Thread Benjamin Peterson
Benjamin Peterson added the comment: Sorry for trampling on you; I had a patch already in my wc. -- nosy: +benjamin.peterson ___ Python tracker ___ __

[issue17722] 'round' function doesn't honour a descriptor __round__

2013-04-13 Thread Roundup Robot
Roundup Robot added the comment: New changeset cc59c215f19e by Benjamin Peterson in branch 'default': properly lookup the __round__ special method (closes #17722) http://hg.python.org/cpython/rev/cc59c215f19e -- nosy: +python-dev resolution: -> fixed stage: patch review -> committed/rej

[issue17722] 'round' function doesn't honour a descriptor __round__

2013-04-13 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Perhaps it will be good to add a new test when X doesn't not have a special method. I don't see this case is covered. -- nosy: +serhiy.storchaka ___ Python tracker _

[issue17722] 'round' function doesn't honour a descriptor __round__

2013-04-13 Thread Mark Dickinson
Mark Dickinson added the comment: Non-leaky patch. -- Added file: http://bugs.python.org/file29821/round_descriptor2.patch ___ Python tracker ___

[issue17722] 'round' function doesn't honour a descriptor __round__

2013-04-13 Thread Mark Dickinson
New submission from Mark Dickinson: Benjamin pointed out on #python-dev that the builtin round function should be using _PyObject_LookupSpecial to look up the __round__ method. Here's a fix. -- components: Interpreter Core files: round_descriptor.patch keywords: patch messages: 186813

[issue17722] 'round' function doesn't honour a descriptor __round__

2013-04-13 Thread Mark Dickinson
Mark Dickinson added the comment: Whoops. That patch introduces a new refleak; will fix shortly. -- ___ Python tracker ___ ___ Pytho