[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Roundup Robot
Roundup Robot added the comment: New changeset cb4c964800af by Victor Stinner in branch 'default': Issue #19514: Add Andrei Dorian Duma to Misc/ACKS for changeset 4a09cc62419b http://hg.python.org/cpython/rev/cb4c964800af -- ___ Python tracker

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Martin v . Löwis
Martin v. Löwis added the comment: Thanks for the patch. Note: moving all identifiers would not have made a difference. They are static variables, so from a run-time point of view, there is no difference whether they are inside or outside of functions. -- resolution: -> fixed status:

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4a09cc62419b by Martin v. Löwis in branch 'default': Issue #19514: Deduplicate some _Py_IDENTIFIER declarations. http://hg.python.org/cpython/rev/4a09cc62419b -- nosy: +python-dev ___ Python tracker

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread STINNER Victor
STINNER Victor added the comment: merge_py_identifiers_sorted.patch looks good to me. -- ___ Python tracker ___ ___ Python-bugs-list m

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Andrei Dorian Duma
Andrei Dorian Duma added the comment: I added a new patch with sorted _Py_IDENTIFIERs. Regarding all identifiers at the top, I guess it might be more stylish, but it might affect performance. I'm not sure, though. -- Added file: http://bugs.python.org/file32533/merge_py_identifiers_sor

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Andrei Dorian Duma
Andrei Dorian Duma added the comment: The patch I promised above. -- Added file: http://bugs.python.org/file32532/merge_py_identifiers.patch ___ Python tracker ___ __

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Martin v . Löwis
Martin v. Löwis added the comment: Another matter of style: I suggest alphabetical order for the identifiers, at least when the list gets long. -- ___ Python tracker ___ ___

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Martin v . Löwis
Martin v. Löwis added the comment: As a matter of style, I suggest that all identifiers are moved to the top of a file if some of them live there. IOW, it's (IMO) unstylish to have some at the top, and some in the middle (although this works perfectly fine, of course). -- nosy: +loewis

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread fhahn
fhahn added the comment: I've merged the _Py_IDENTIFIER identifiers mentioned above. I stumbled over anohter instance where _Py_IDENTIFIER is used more than once: _Py_IDENTIFIER(__setitem__) : Objects/typeobject.c#l5133 _Py_IDENTIFIER(__setitem__) : Objects/typeobject.c#l5184 -- keywo

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Ian Cordasco
Changes by Ian Cordasco : -- nosy: +icordasc ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pytho

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Seydou Dia
Changes by Seydou Dia : -- nosy: +seydou ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.or

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-07 Thread Andrei Dorian Duma
Andrei Dorian Duma added the comment: I'll provide a patch later tonight. -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-06 Thread STINNER Victor
STINNER Victor added the comment: Oh, I forgot: _Py_IDENTIFIER(__delitem__): Objects/typeobject.c:5132 _Py_IDENTIFIER(__delitem__): Objects/typeobject.c:5183 -- ___ Python tracker _

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-06 Thread Andrei Dorian Duma
Changes by Andrei Dorian Duma : -- nosy: +andrei.duma ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://m

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-06 Thread STINNER Victor
STINNER Victor added the comment: See also issue #19515 which is more general. -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue19514] Merge duplicated _Py_IDENTIFIER identifiers in C code

2013-11-06 Thread STINNER Victor
New submission from STINNER Victor: Some C files use more than once the same _Py_IDENTIFIER identifier. It would be more efficient to merge duplicated identifiers. Just move the definition to the top of the file. _Py_IDENTIFIER(as_integer_ratio): Modules/_datetimemodule.c:1569 _Py_IDENTIFIER(a