diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2000-04-25 17:37:54 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2000-04-25 17:37:54 +0000 |
commit | cc255d5f98c29ad53a83e8a6c100b03ac8715700 (patch) | |
tree | 9b38fd716bbb2b06b9eaaaa4316ffd0141a58320 /pod/perlop.pod | |
parent | dff3e0b830e328ebcc74f828846237175fcfa600 (diff) | |
download | perl-cc255d5f98c29ad53a83e8a6c100b03ac8715700.tar.gz |
Document that tr() is not tr(1).
p4raw-id: //depot/cfgperl@5946
Diffstat (limited to 'pod/perlop.pod')
-rw-r--r-- | pod/perlop.pod | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/pod/perlop.pod b/pod/perlop.pod index d847c99ab3..174cf00602 100644 --- a/pod/perlop.pod +++ b/pod/perlop.pod @@ -1225,6 +1225,12 @@ SEARCHLIST is delimited by bracketing quotes, the REPLACEMENTLIST has its own pair of quotes, which may or may not be bracketing quotes, e.g., C<tr[A-Z][a-z]> or C<tr(+\-*/)/ABCD/>. +Note that C<tr> does B<not> do regular expression character classes +such as C<\d> or C<[:lower:]>. The <tr> operator is not equivalent to +the tr(1) utility. If you want to map strings between lower/upper +cases, see L<perlfunc/lc> and L<perlfunc/uc>, and in general consider +using the C<s> operator if you need regular expressions. + Note also that the whole range idea is rather unportable between character sets--and even within character sets they may cause results you probably didn't expect. A sound principle is to use only ranges |