This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Upgrade to Module-Build-0.2803
[perl5.git] / lib / diagnostics.pm
index 213638f..e81581b 100755 (executable)
@@ -185,7 +185,7 @@ use 5.006;
 use Carp;
 $Carp::Internal{__PACKAGE__.""}++;
 
-our $VERSION = 1.15;
+our $VERSION = 1.16;
 our $DEBUG;
 our $VERBOSE;
 our $PRETTY;
@@ -466,12 +466,12 @@ sub import {
                                    $PRETTY++;
                                    next;
                               };
-
-       /^-t(race)?$/           && do {
+       # matches trace and traceonly for legacy doc mixup reasons
+       /^-t(race(only)?)?$/    && do {
                                    $TRACEONLY++;
                                    next;
                               };
-       /^-w(arntrace)?$/               && do {
+       /^-w(arntrace)?$/       && do {
                                    $WARNTRACE++;
                                    next;
                               };
@@ -562,6 +562,7 @@ sub splainthis {
     # but be aware of messsages containing " at this-or-that"
     my $real = 0;
     my @secs = split( / at / );
+    return unless @secs;
     $_ = $secs[0];
     for my $i ( 1..$#secs ){
         if( $secs[$i] =~ /.+? (?:line|chunk) \d+/ ){