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.
Created on 2012年05月05日 01:14 by gregory.p.smith, last changed 2022年04月11日 14:57 by admin. This issue is now closed.
| Messages (4) | |||
|---|---|---|---|
| msg159974 - (view) | Author: Gregory P. Smith (gregory.p.smith) * (Python committer) | Date: 2012年05月05日 01:14 | |
Lib/email/*.py are fond of using EMPTYSTRING = '' and within the code: EMPTYSTRING.join(...) instead of just writing: ''.join(...) They should just do the latter. It'll avoid a name lookup and look less silly to people reading the code. ;) |
|||
| msg159975 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2012年05月05日 01:25 | |
I've always wondered why the code did that. If Barry doesn't have a good reason for it, I'll refactor it at some point. |
|||
| msg159978 - (view) | Author: Barry A. Warsaw (barry) * (Python committer) | Date: 2012年05月05日 05:15 | |
On May 05, 2012, at 01:25 AM, R. David Murray wrote: >I've always wondered why the code did that. If Barry doesn't have a good >reason for it, I'll refactor it at some point. A long time ago, Tim (IIRC) expressed an opinion that using the variable makes the code more readable. After having seen so much code that uses the string literals over the years, I wholeheartedly agree with that opinion. |
|||
| msg159989 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2012年05月05日 13:24 | |
Good enough for me. I personally don't find it to be easier or harder to read with the names, so let's keep them. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:57:29 | admin | set | github: 58931 |
| 2012年05月05日 13:24:30 | r.david.murray | set | status: open -> closed resolution: works for me messages: + msg159989 stage: resolved |
| 2012年05月05日 05:15:53 | barry | set | messages: + msg159978 |
| 2012年05月05日 01:25:41 | r.david.murray | set | nosy:
+ barry, r.david.murray messages: + msg159975 assignee: r.david.murray type: performance |
| 2012年05月05日 01:14:07 | gregory.p.smith | create | |