=head2 Perl Source Incompatibilities
-Beware that any new warnings that have been added are B<not> considered
-incompatible changes.
+Beware that any new warnings that have been added or enhanced old
+warnings are B<not> considered incompatible changes.
Since all new warnings must be explicitly requested via the C<-w>
switch or the C<warnings> pragma, it is ultimately the programmer's
included with the standard Perl distribution) may also be of use, it
offers the getrlimit/setrlimit interface that can be used to adjust
process resource usage limits, including the maximum filesize limit.
-
+
=head2 Long doubles
In some systems you may be able to use long doubles to enhance the
is used.
Note that something resembling the previous behavior can still be
-obtained by putting C<BEGIN { $^C = 0; exit; } at the very end of
+obtained by putting C<BEGIN { $^C = 0; exit; }> at the very end of
the top level source file.
=head2 Potential to leak DATA filehandles
=item Data::Dumper
A C<Maxdepth> setting can be specified to avoid venturing
-too deeply into depp data structures. See L<Data::Dumper>.
+too deeply into deep data structures. See L<Data::Dumper>.
Dumping C<qr//> objects works correctly.
=item Devel::DProf
-Devel::DProf, a Perl source code profiler has been added. See L<DProf>.
+Devel::DProf, a Perl source code profiler has been added. See
+L<Devel::DProf> and L<dprofpp>.
=item Dumpvalue
=item Benchmark
+Overall, Benchmark results exhibit lower average error and better timing
+accuracy.
+
You can now run tests for I<n> seconds instead of guessing the right
number of tests to run: e.g. timethese(-5, ...) will run each
code for at least 5 CPU seconds. Zero as the "number of repetitions"
means "for at least 3 CPU seconds". The output format has also
changed. For example:
-use Benchmark;$x=3;timethese(-5,{a=>sub{$x*$x},b=>sub{$x**2}})
+ use Benchmark;$x=3;timethese(-5,{a=>sub{$x*$x},b=>sub{$x**2}})
will now output something like this:
-Benchmark: running a, b, each for at least 5 CPU seconds...
- a: 5 wallclock secs ( 5.77 usr + 0.00 sys = 5.77 CPU) @ 200551.91/s (n=1156516)
- b: 4 wallclock secs ( 5.00 usr + 0.02 sys = 5.02 CPU) @ 159605.18/s (n=800686)
+ Benchmark: running a, b, each for at least 5 CPU seconds...
+ a: 5 wallclock secs ( 5.77 usr + 0.00 sys = 5.77 CPU) @ 200551.91/s (n=1156516)
+ b: 4 wallclock secs ( 5.00 usr + 0.02 sys = 5.02 CPU) @ 159605.18/s (n=800686)
New features: "each for at least N CPU seconds...", "wallclock secs",
and the "@ operations/CPU second (n=operations)".
-change#4265,4266,4292
-[TODO - Barrie Slaymaker <barries@slaysys.com>]
+timethese() now returns a reference to a hash of Benchmark objects containing
+the test results, keyed on the names of the tests.
+
+timethis() now returns the iterations field in the Benchmark result object
+instead of 0.
+
+timethese(), timethis(), and the new cmpthese() (see below) can also take
+a format specifier of 'none' to suppress output.
+
+A new function countit() is just like timeit() except that it takes a
+TIME instead of a COUNT.
+
+A new function cmpthese() prints a chart comparing the results of each test
+returned from a timethese() call. For each possible pair of tests, the
+percentage speed difference (iters/sec or seconds/iter) is shown.
+
+For other details, see L<Benchmark>.
=item Devel::Peek
An introduction to using the Perl Compiler suite.
+=item perlfilter.pod
+
+An introduction to writing Perl source filters.
+
=item perlhack.pod
Some guidelines for hacking the Perl source code.
=back
-=head1 New Diagnostics
+=head1 New or Changed Diagnostics
=over 4
but this did not follow some numeric unpack specification.
See L<perlfunc/pack>.
-=item Repeat count in pack overflows
-
-(F) You can't specify a repeat count so large that it overflows
-your signed integers. See L<perlfunc/pack>.
-
-=item Repeat count in unpack overflows
-
-(F) You can't specify a repeat count so large that it overflows
-your signed integers. See L<perlfunc/unpack>.
-
=item /%s/: Unrecognized escape \\%c passed through
(W) You used a backslash-character combination which is not recognized
by Perl. This combination appears in an interpolated variable or a
-C<'>-delimited regular expression.
+C<'>-delimited regular expression. The character was understood literally.
+
+=item /%s/: Unrecognized escape \\%c in character class passed through
+
+(W) You used a backslash-character combination which is not recognized
+by Perl inside character classes. The character was understood literally.
=item /%s/ should probably be written as "%s"
(P) For some reason you can't check the filesystem of the script for nosuid.
+=item Can't ignore signal CHLD, forcing to default
+
+(W) Perl has detected that it is being run with the SIGCHLD signal
+(sometimes known as SIGCLD) disabled. Since disabling this signal
+will interfere with proper determination of exit status of child
+processes, Perl has reset the signal to its default value.
+This situation typically indicates that the parent program under
+which Perl may be running (e.g. cron) is being very careless.
+
=item Can't modify non-lvalue subroutine call
(F) Subroutines meant to be used in lvalue context should be declared as
(F) While under the C<use filetest> pragma, switching the real and
effective uids or gids failed.
+=item false [] range "%s" in regexp
+
+(W) A character class range must start and end at a literal character, not
+another character class like C<\d> or C<[:alpha:]>. The "-" in your false
+range is interpreted as a literal "-". Consider quoting the "-", "\-".
+See L<perlre>.
+
=item Filehandle %s opened only for output
(W) You tried to read from a filehandle opened only for writing. If you
The indicated attributes for a subroutine or variable were not recognized
by Perl or by a user-supplied handler. See L<attributes>.
+=item invalid [] range "%s" in regexp
+
+The offending range is now explicitly displayed.
+
=item Invalid separator character %s in attribute list
(F) Something other than a comma or whitespace was seen between the
See Server error.
+=item Repeat count in pack overflows
+
+(F) You can't specify a repeat count so large that it overflows
+your signed integers. See L<perlfunc/pack>.
+
+=item Repeat count in unpack overflows
+
+(F) You can't specify a repeat count so large that it overflows
+your signed integers. See L<perlfunc/unpack>.
+
=item realloc() of freed memory ignored
(S) An internal routine called realloc() on something that had already
=item Unrecognized escape \\%c passed through
(W) You used a backslash-character combination which is not recognized
-by Perl.
+by Perl. The character was understood literally.
=item Unterminated attribute parameter in attribute list