Lines Matching defs:runperl
340 # runperl - Runs a separate perl interpreter.
358 my ($runperl, $args) = @_;
364 $$runperl .= ' ' . $_;
368 sub _create_runperl { # Create the string to qx in runperl().
370 my $runperl = $^X =~ m/\s/ ? qq{"$^X"} : $^X;
373 $runperl .= ' -I::lib';
375 $runperl .= ' -MMac::err=unix' if $args{stderr};
378 $runperl .= ' "-I../lib"'; # doublequotes because of VMS
383 die "test.pl:runperl(): 'switches' must be an ARRAYREF " . _where()
385 _quote_args(\$runperl, $args{switches});
388 die "test.pl:runperl(): both 'prog' and 'progs' cannot be used " . _where()
393 die "test.pl:runperl(): 'progs' must be an ARRAYREF " . _where()
397 $runperl .= qq ( -e "$prog" );
400 $runperl .= qq ( -e '$prog' );
404 $runperl .= qq( "$args{progfile}");
413 $runperl = qq{$^X -e "print qq(} .
414 $args{stdin} . q{)" | } . $runperl;
427 $runperl .= q{ < teststdin };
430 $runperl = qq{$^X -e 'print qq(} .
431 $args{stdin} . q{)' | } . $runperl;
435 _quote_args(\$runperl, $args{args});
437 $runperl .= ' 2>&1' if $args{stderr} && !$is_macos;
438 $runperl .= " \xB3 Dev:Null" if !$args{stderr} && $is_macos;
440 my $runperldisplay = $runperl;
444 return $runperl;
447 sub runperl {
448 my $runperl = &_create_runperl;
449 my $result = `$runperl`;
454 *run_perl = \&runperl; # Nice alias.
551 my $results = runperl(%$runperl_args);