Commit | Line | Data |
---|---|---|
9021a1cf A |
1 | =head1 NAME |
2 | ||
3 | perldeprecation - list Perl deprecations | |
4 | ||
5 | =head1 DESCRIPTION | |
6 | ||
7 | The purpose of this document is to document what has been deprecated | |
8 | in Perl, and by which version the deprecated feature will disappear, | |
9 | or, for already removed features, when it was removed. | |
10 | ||
11 | This document will try to discuss what alternatives for the deprecated | |
12 | features are available. | |
13 | ||
14 | The deprecated features will be grouped by the version of Perl in | |
15 | which they will be removed. | |
16 | ||
a0e213fc A |
17 | =head2 Perl 5.30 |
18 | ||
19 | =head3 C<< File::Glob::glob() >> will disappear | |
20 | ||
21 | C<< File::Glob >> has a function called C<< glob >>, which just calls | |
22 | C<< bsd_glob >>. However, its prototype is different from the prototype | |
23 | of C<< CORE::glob >>, and hence, C<< File::Glob::glob >> should not | |
24 | be used. | |
25 | ||
3da1a3d5 A |
26 | C<< File::Glob::glob() >> was deprecated in perl 5.8. A deprecation |
27 | message was issued from perl 5.26 onwards, and the function will | |
28 | disappear in perl 5.30. | |
a0e213fc A |
29 | |
30 | Code using C<< File::Glob::glob() >> should call | |
31 | C<< File::Glob::bsd_glob() >> instead. | |
32 | ||
9021a1cf A |
33 | =head2 Perl 5.24 |
34 | ||
35 | =head3 Use of C<< *glob{FILEHANDLE} >> | |
36 | ||
3da1a3d5 | 37 | The use of C<< *glob{FILEHANDLE} >> was deprecated in perl 5.8. |
9021a1cf A |
38 | The intention was to use C<< *glob{IO} >> instead, for which |
39 | C<< *glob{FILEHANDLE} >> is an alias. | |
40 | ||
3da1a3d5 | 41 | However, this feature was undeprecated in perl 5.24. |
9021a1cf | 42 | |
46d7f3c1 A |
43 | =head3 Calling POSIX::%s() is deprecated |
44 | ||
45 | The following functions in the C<POSIX> module are no longer available: | |
46 | C<isalnum>, C<isalpha>, C<iscntrl>, C<isdigit>, C<isgraph>, C<islower>, | |
47 | C<isprint>, C<ispunct>, C<isspace>, C<isupper>, and C<isxdigit>. The | |
48 | functions are buggy and don't work on UTF-8 encoded strings. See their | |
49 | entries in L<POSIX> for more information. | |
50 | ||
3da1a3d5 | 51 | The functions were deprecated in perl 5.20, and removed in perl 5.24. |
46d7f3c1 A |
52 | |
53 | ||
c4d8d6a2 A |
54 | =head2 Perl 5.16 |
55 | ||
56 | =head3 Use of %s on a handle without * is deprecated | |
57 | ||
58 | It used to be possible to use C<tie>, C<tied> or C<untie> on a scalar | |
59 | while the scalar holds a typeglob. This caused its filehandle to be | |
60 | tied. It left no way to tie the scalar itself when it held a typeglob, | |
61 | and no way to untie a scalar that had had a typeglob assigned to it. | |
62 | ||
3da1a3d5 | 63 | This was deprecated in perl 5.14, and the bug was fixed in perl 5.16. |
c4d8d6a2 A |
64 | |
65 | So now C<tie $scalar> will always tie the scalar, not the handle it holds. | |
66 | To tie the handle, use C<tie *$scalar> (with an explicit asterisk). The same | |
67 | applies to C<tied *$scalar> and C<untie *$scalar>. | |
68 | ||
69 | ||
9021a1cf A |
70 | =head1 SEE ALSO |
71 | ||
72 | L<warnings>, L<diagnostics>. | |
73 | ||
74 | =cut |