[issue15422] Get rid of PyCFunction_New macro
Antoine Pitrou added the comment: Regression in issue #21354. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Roundup Robot added the comment: New changeset 267ad2ed4138 by Andrew Kuchling in branch 'default': #15422: remove NEWS item for a change that was later reverted http://hg.python.org/cpython/rev/267ad2ed4138 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Roundup Robot added the comment: New changeset 6a56eaa5e5fb by Andrew Svetlov in branch 'default': Revert back PyCFunction_New macro. Keep PyCFunction_NewEx usage in python core modules (#15422) http://hg.python.org/cpython/rev/6a56eaa5e5fb -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Andrew Svetlov added the comment: Georg, I've followed your instructions. Close the issue again. Thanks for mentorship. -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Roundup Robot added the comment: New changeset 70ea05f762a1 by Andrew Svetlov in branch 'default': Fix compilation error for #15422 http://hg.python.org/cpython/rev/70ea05f762a1 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Andrew Svetlov added the comment: #16776 created for documenting PyCFunction_New/PyCFunction_NewEx -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Roundup Robot added the comment: New changeset 3a86a3f1d89a by Andrew Svetlov in branch 'default': Issue #15422: get rid of PyCFunction_New macro http://hg.python.org/cpython/rev/3a86a3f1d89a -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Changes by Andrew Svetlov andrew.svet...@gmail.com: -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Georg Brandl added the comment: I don't think this is the only use of this particular idiom; I recall it is used every time we amend a function with an _Ex version. Why was this change necessary? -- nosy: +georg.brandl, pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Georg Brandl added the comment: BTW it would be good if you could have at least one other developer look at issues like this and get a LGTM vote before committing all by yourself. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Andrew Svetlov added the comment: 1. Yes, you right. We use this idiom also for PyAST_CompileEx, PyErr_WarnEx and bunch of functions in ./Include/pythonrun.h 2. Patch is very simple and was available for review almost 3 months. I assumed that developers looked on this and had no objections. Sorry if I was wrong. 3. The change is not required. But, I think, it can be helpful to use direct function calls instead of macros, especially for functions which are part of Stable API. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Georg Brandl added the comment: There is no silent acceptance. No comment means that nobody reviewed it, which is no surprise given the number of open issues :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Georg Brandl added the comment: So given #1 and #3, I would recommend reverting the part of the patch that removes the macro. Changing caller sites in CPython sources is fine. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Changes by Andrew Svetlov andrew.svet...@gmail.com: -- resolution: fixed - stage: committed/rejected - status: closed - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Andrew Svetlov added the comment: Attached patch for the issue. BTW PyCFunction_New/PyCFunction_NewEx are part of Stable ABI but never mentioned in the documentation. -- keywords: +patch Added file: http://bugs.python.org/file27453/issue15422.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
Changes by Andrew Svetlov andrew.svet...@gmail.com: -- stage: needs patch - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15422] Get rid of PyCFunction_New macro
New submission from Andrew Svetlov andrew.svet...@gmail.com: For now (3.3 beta) PyCFunction_New defined as macro calling PyCFunction_NewEx. To be compatible with PEP 384 (Defining a Stable ABI) Objects/methodobject.c has trampoline function named PyCFunction_New which calls PyCFunction_NewEx. This is only single usage of this idiom in CPython code. For sake of uniformity we need to: - remove PyCFunction_New macro from Include/methodobject.h - declare PyCFunction_New as function in Include/methodobject.h - replace all calls of PyCFunction_New to PyCFunction_NewEx in code (about 8 occurrences). -- assignee: asvetlov components: Interpreter Core messages: 166138 nosy: asvetlov, loewis priority: normal severity: normal stage: needs patch status: open title: Get rid of PyCFunction_New macro type: enhancement versions: Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15422 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com