Issue 21990: saxutils defines an inner class where a normal one would do (original ) (raw ) Issue21990
Created on 2014-07-16 14:28 by alex , last changed 2022-04-11 14:58 by admin . This issue is now closed .
Files
File name
Uploaded
Description
Edit
sax.diff
alex,2014-07-16 14:28
review
Messages (4)
msg223209 - (view)
Author: Alex Gaynor (alex) *
Date: 2014-07-16 14:28
This makes things slower than they need to be (yes, even on CPython :-)), and is slightly confusing since usually inner classes are only used when a closure is needed. Attached patch simply moves the class definition.
msg223779 - (view)
Author: Eric V. Smith (eric.smith) *
Date: 2014-07-23 21:15
Looks fine to me. Normally I'd define the class being returned before the function returning it, but it doesn't really make a difference.
msg223808 - (view)
Author: Serhiy Storchaka (serhiy.storchaka) *
Date: 2014-07-24 05:17
LGTM. But it would be better to add underscore prefix to class name.
msg223973 - (view)
Author: Roundup Robot (python-dev)
Date: 2014-07-25 17:26
New changeset a5cb10f2dbaa by Raymond Hettinger in branch '2.7': Issue #21990 : Cleanup unnecessary inner class definition in saxutils. http://hg.python.org/cpython/rev/a5cb10f2dbaa
History
Date
User
Action
Args
2022-04-11 14:58:06
admin
set
github: 66189
2014-07-27 16:34:05
berker.peksag
set
stage: commit review -> resolved
2014-07-25 18:30:47
rhettinger
set
status: open -> closedresolution: fixed
2014-07-25 17:26:44
python-dev
set
nosy: + python-dev messages: +
2014-07-25 17:14:00
rhettinger
set
assignee: rhettinger nosy: + rhettinger
2014-07-24 05:17:25
serhiy.storchaka
set
nosy: + serhiy.storchaka messages: + stage: commit review
2014-07-23 21:15:21
eric.smith
set
nosy: + eric.smith messages: +
2014-07-16 17:45:17
alex
set
keywords: + needs review
2014-07-16 17:44:40
ned.deily
set
nosy: + christian.heimes
2014-07-16 14:28:48
alex
create