From f193aa2f4863bc10ce670744f734970587651ac5 Mon Sep 17 00:00:00 2001 From: "Michael G. Schwern" Date: Fri, 14 Dec 2001 15:59:42 -0500 Subject: [PATCH] -bytecompile & -compile for testing perlcc Message-ID: <20011215015942.GF28596@blackrider> p4raw-id: //depot/perl@13699 --- t/TEST | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/t/TEST b/t/TEST index 4c033d5..278097a 100755 --- a/t/TEST +++ b/t/TEST @@ -16,6 +16,8 @@ if ($#ARGV >= 0) { $core = 1 if $1 eq 'core'; $verbose = 1 if $1 eq 'v'; $with_utf= 1 if $1 eq 'utf8'; + $byte_compile = 1 if $1 eq 'bytecompile'; + $compile = 1 if $1 eq 'compile'; if ($1 =~ /^deparse(,.+)?$/) { $deparse = 1; $deparse_opts = $1; @@ -97,14 +99,20 @@ unless (@ARGV) { %infinite = (); if ($deparse) { - _testprogs('deparse', @ARGV); -} else { - _testprogs('perl', @ARGV); - _testprogs('compile', @ARGV) if (-e "../testcompile"); + _testprogs('deparse', '', @ARGV); +} +elsif( $compile || $byte_compile ) { + _testprogs('compile', '', @ARGV) if $compile; + _testprogs('compile', '-B', @ARGV) if $byte_compile; +} +else { + _testprogs('compile', '', @ARGV) if -e "../testcompile"; + _testprogs('perl', '', @ARGV); } sub _testprogs { $type = shift @_; + $args = shift; @tests = @_; print <<'EOT' if ($type eq 'compile'); @@ -201,7 +209,7 @@ EOT } else { my $compile = - "./perl $testswitch -I../lib ../utils/perlcc -o ". + "./perl $testswitch -I../lib ../utils/perlcc -I .. $args -o ". "$test.plc $utf $test ". " && $test.plc |"; open(RESULTS, $compile) -- 2.7.4