Avoid using -> function call notation within test.pl, which is supposed
Nicholas Clark [Tue, 1 Jul 2008 14:34:21 +0000 (14:34 +0000)]
to keep to simple constructions to facilitate accurately testing the
core interpreter, which might be buggy.

p4raw-id: //depot/perl@34097

t/test.pl

index 2caf2e8..d697f77 100644 (file)
--- a/t/test.pl
+++ b/t/test.pl
@@ -69,9 +69,7 @@ sub _diag {
     return unless @_;
     my @mess = map { /^#/ ? "$_\n" : "# $_\n" }
                map { split /\n/ } @_;
-    my $func = $TODO ? \&_print : \&_print_stderr;
-    $func->(@mess);
-
+    $TODO ? _print(@mess) : _print_stderr(@mess);
 }
 
 sub diag {