Message93220
The string module, however, fails to properly capitalize anything in quotes:
>>> string.capwords("i pity the 'foo'.")
"I Pity The 'foo'."
The string module could be easily made to work like the object. The
object could be made to work more like the module, only capitalizing
things after a space and the start of the string, but I'm not really
sure that it's any better. (The s.istitle() should also be updated if
s.title() is changed.) The inconsistency is pretty nasty, though, and
the documentation should probably be more specific about what's going on. |
|
Date |
User |
Action |
Args |
2009-09-28 17:51:18 | twb | set | recipients:
+ twb, markon, nickd |
2009-09-28 17:51:18 | twb | set | messageid: <1254160278.82.0.100931518496.issue7008@psf.upfronthosting.co.za> |
2009-09-28 17:51:17 | twb | link | issue7008 messages |
2009-09-28 17:51:17 | twb | create | |
|