diff options
author | Michael G. Schwern <schwern@pobox.com> | 2001-11-26 22:38:24 -0500 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-11-27 13:23:28 +0000 |
commit | 2f6bec1d718b5383182c91d0fb6c38b9facd1c87 (patch) | |
tree | 303575f5e0d2412997555fa2929e3854520c6206 /t/TEST | |
parent | 330249434827c286fab76069a79e5c9b701923fc (diff) | |
download | perl-2f6bec1d718b5383182c91d0fb6c38b9facd1c87.tar.gz |
Remove redundant #! parsing. Deparse tests better.
Message-ID: <20011127033824.A17775@blackrider>
p4raw-id: //depot/perl@13310
Diffstat (limited to 't/TEST')
-rwxr-xr-x | t/TEST | 22 |
1 files changed, 9 insertions, 13 deletions
@@ -163,19 +163,15 @@ EOT $test = $OVER{$test} if exists $OVER{$test}; - open(SCRIPT,"<$test") or die "Can't run $test.\n"; - $_ = <SCRIPT>; - close(SCRIPT) unless ($type eq 'deparse'); - if (/#!.*perl(.*)$/) { - $switch = $1; - if ($^O eq 'VMS') { - # Must protect uppercase switches with "" on command line - $switch =~ s/-([A-Z]\S*)/"-$1"/g; - } - } - else { - $switch = ''; - } + open(SCRIPT,"<$test") or die "Can't run $test.\n"; + $_ = <SCRIPT>; + close(SCRIPT) unless ($type eq 'deparse'); + if (/#!.*\bperl.*-\w*T/) { + $switch = '"-T"'; + } + else { + $switch = ''; + } my $file_opts = ""; if ($type eq 'deparse') { |