From a3eebe60dc7ad854020ae839270f35b137c2893d Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Thu, 11 Jun 1998 16:03:30 +0000 Subject: [PATCH] Add warning about use of lowercase/uppercase with maketrans(). --- Doc/lib/libstring.tex | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Doc/lib/libstring.tex b/Doc/lib/libstring.tex index 39392296842..7d6f4bdaae0 100644 --- a/Doc/lib/libstring.tex +++ b/Doc/lib/libstring.tex @@ -144,6 +144,11 @@ Return a translation table suitable for passing to \function{translate()} or \function{regex.compile()}, that will map each character in \var{from} into the character at the same position in \var{to}; \var{from} and \var{to} must have the same length. + +\strong{Warning:} don't use strings derived from \code{lowercase} and +\code{uppercase} as arguments; in some locales, these don't have the +same length. For case conversions, always use \function{lower()} and +\function{upper()}. \end{funcdesc} \begin{funcdesc}{split}{s\optional{, sep\optional{, maxsplit}}}