[issue8347] string capitalize erroneously lower-case any non-first letters

2010-04-08 Thread Martin

New submission from Martin famar...@gmail.com:

When the following is run:
  s='the Los Angeles Symphony';
  s.capitalize();
it displays 'The los angeles symphony'
instead of 'The Los Angeles Symphony'

the str.capitalize() should only deal with the first letter, not lower-case the 
rest of the letters. The manual correctly describes this, but the actual 
behavior is not consistent with this description.

--
components: None
messages: 102629
nosy: famart
severity: normal
status: open
title: string capitalize erroneously lower-case any non-first letters
type: behavior
versions: Python 2.6

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8347
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue8347] string capitalize erroneously lower-case any non-first letters

2010-04-08 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

S.capitalize() - string

Return a copy of the string S with only its first character
capitalized.

You've misunderstood the docs, only the first character is indeed capitalized. 
You want string.capwords instead

--
nosy: +pjenvey
resolution:  - invalid
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8347
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com