Modify ↓
#1857 closed defect (fixed)
[PATCH] Refactoring: spam[:4] == 'eggs' => spam.startswith('eggs')
Reported by: | Owned by: | Jonas Borgström | |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | general | Version: | 0.8.4 |
Severity: | normal | Keywords: | |
Cc: | Branch: | ||
Release Notes: | |||
API Changes: | |||
Internal Changes: |
Description
This is a patch against [2037] that changes occurrences of
spam[:4] == 'eggs' spam[-4:] == 'eggs'
to
spam.startswith('eggs') spam.endswith('eggs')
This conforms with the Python style guide.
Attachments (1)
Change History (2)
by , 19 years ago
Attachment: | startswith_r2037.patch added |
---|
comment:1 by , 19 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Ah yes, this is actually a pet peeve of mine too. Committed in [2038].
Note:
See TracTickets
for help on using tickets.
Patch against [2037]