• Home
  • Raw
  • Download

Lines Matching +full:- +full:outfile

5 # argument is -perl then the second is taken as the Perl command to use, and
6 # both are then removed. If the next argument is "-w", Perl is called with
7 # "-w", which turns on its warning mode.
10 # running UTF-8 tests, but *not* for non-utf8 tests. (The "require" would
11 # actually be OK for non-utf8-tests, but is not always installed, so this way
15 # Perl script to Perl through a pipe. If the next argument is "-utf8", a
28 if [ $# -gt 1 -a "$1" = "-perl" ] ; then
34 if [ $# -gt 0 -a "$1" = "-w" ] ; then
35 perlarg="-w"
39 if [ $# -gt 0 -a "$1" = "-utf8" ] ; then
57 # -no_start_optimize ignored
60 # utf invoke UTF-8 functionality
69 # are ignored. Any other #-command is ignored, with a warning message.
76 # Perl double-quoted strings, so if they contain " $ or @ characters, these
78 # Perl-compatible testinput1 and testinput4 files are escaped so that they can
89 # The alpha assertions currently give warnings even when -w is not specified.
141 open(OUTFILE, ">$ARGV[1]") || die "Failed to open $ARGV[1]\n";
142 $outfile = "OUTFILE";
144 else { $outfile = "STDOUT"; }
146 printf($outfile "Perl $^V\n\n");
158 printf $outfile "$_" if ! $interact;
161 # A few of pcre2test's #-commands are supported, or just ignored. Any others
176 if ($mod =~ s/(-?)mark,?//)
183 printf $outfile "** Warning: \"$mod\" in #subject ignored\n";
191 printf $outfile "** Warning: #-command ignored: %s", $_;
202 printf $outfile "$_" if ! $interact;
253 # Use no_start_optimize (disable PCRE2 start-up optimization) to disable Perl
255 # also encounter -no_start_optimize from a #pattern setting.
257 $mod =~ s/-no_start_optimize,?//;
269 printf $outfile "Error: $@";
284 $cmd = ($pattern =~ /g[a-z]*\s*$/)? "while" : "if";
289 # in places - if they are allowed through here all sorts of weird and
291 # a non-null pattern that has the same effect.
302 printf $outfile "%s", "$_\n" if ! $interact;
350 printf $outfile "Error: $@\n";
355 printf $outfile "No match";
357 { printf $outfile (", mark = %s", &pchars($REGERROR)); }
358 printf $outfile "\n";
364 printf $outfile (" 0: %s\n", &pchars($subs[0]));
365 printf $outfile (" 0+ %s\n", &pchars($subs[17])) if $showrest;
371 while ($last_printed++ < $i-1)
372 { printf $outfile ("%2d: <unset>\n", $last_printed); }
373 printf $outfile ("%2d: %s\n", $i, &pchars($subs[$i]));
380 # It seems that $REGMARK is not marked as UTF-8 even when use utf8 is
381 # set and the input pattern was a UTF-8 string. We can, however, force
388 printf $outfile ("MK: %s\n", &pchars($xx));
394 # By closing OUTFILE explicitly, we avoid a Perl warning in -w mode
395 # "main::OUTFILE" used only once".
397 close(OUTFILE) if $outfile eq "OUTFILE";
400 ) | $perl $perlarg - $@