From 8ebc5c0145d2e3559bce3073437e6d027dcdffcc Mon Sep 17 00:00:00 2001 From: Perl 5 Porters Date: Sat, 4 Jan 1997 17:44:00 +1200 Subject: [inseparable changes from patch from perl5.003_18 to perl5.003_19] CORE LANGUAGE CHANGES Subject: Make method cache invisible to user code From: Chip Salzenberg Files: dump.c gv.c gv.h hv.c op.c perl.c pp_hot.c pp_sys.c sv.c toke.c Subject: Never parse "{m,s,y,tr,q{,q,w,x}}:{,:}" as package or label From: Chip Salzenberg Files: toke.c CORE PORTABILITY Subject: Fix $^X under HP-UX From: Chip Salzenberg Files: hints/hpux.sh toke.c Subject: New hints/hpux.sh Date: Tue, 31 Dec 1996 15:09:32 -0800 From: Jeff Okamoto Files: hints/hpux.sh private-msgid: <199612312309.AA283393772@hpcc123.corp.hp.com> DOCUMENTATION Subject: Perlguts, version 28 Date: Fri, 3 Jan 1997 13:10:46 -0800 From: Jeff Okamoto Files: pod/perlguts.pod private-msgid: <199701032110.AA102535846@hpcc123.corp.hp.com> Subject: Miscellaneous pod patches From: Ralf S. Engelschall Files: pod/Makefile pod/perldebug.pod pod/perlfunc.pod pod/perlguts.pod Subject: expanded flock() docs Date: Fri, 03 Jan 1997 19:31:11 -0500 From: Roderick Schertler Files: pod/perlfunc.pod Msg-ID: <4481.852337871@eeyore.ibcinc.com> (applied based on p5p patch as commit 1fd81fbbe87d964ad1f7dbdce41e36f3781dcf82) Subject: Use Text::Wrap in buildtoc; run buildtoc From: Ulrich Pfeifer Files: pod/buildtoc pod/perltoc.pod Subject: Remove obsolete perlovl.pod From: Chip Salzenberg Files: MANIFEST plan9/mkfile pod/perlovl.pod vms/Makefile vms/descrip.mms OTHER CORE CHANGES Subject: Fix segv when calling named closures From: Chip Salzenberg Files: pp_hot.c Subject: Finish rationalizing "undef value" warnings From: Chip Salzenberg Files: doop.c pp.c sv.c t/op/assignwarn.t Subject: Arrange for all "_ Files: gv.c lib/perl5db.pl Subject: Introduce CVf_NODEBUG flag Date: Wed, 01 Jan 1997 15:42:05 -0500 From: Gurusamy Sarathy Files: cv.h pp_hot.c Msg-ID: <199701012042.PAA25994@aatma.engin.umich.edu> (applied based on p5p patch as commit a3d90dd510fe5a67ed9b80e603493d285c30aa97) Subject: Reword 'may be "0"' warning per Larry; fix its line number From: Chip Salzenberg Files: op.c pod/perldiag.pod Subject: 5.003_18: perl_{con,des}truct fixes Date: Fri, 03 Jan 1997 15:42:04 -0500 From: Doug MacEachern Files: perl.c perl.h pod/perlembed.pod pod/perltoc.pod t/op/sysio.t Msg-ID: <199701032042.PAA06766@postman.osf.org> (applied based on p5p patch as commit 316c7b3d7b47e3143f94c7f8621e854c519d1e87) Subject: Fix lost value from READLINE after TIEHANDLE From: Gurusamy Sarathy Files: pp_hot.c sv.h TESTS Subject: Create t/pragma directory; populate with new and old From: Paul Marquess Files: MANIFEST Makefile.SH t/TEST t/comp/use.t t/lib/locale.t t/op/overload.t t/op/use.t t/pragma/locale.t t/pragma/overload.t t/pragma/strict-refs t/pragma/strict-subs t/pragma/strict-vars t/pragma/strict.t t/pragma/subs.t t/pragma/warn-global t/pragma/warning.t Subject: New tests: comp/colon.t and op/assignwarn.t From: Robin Barker Files: MANIFEST t/comp/colon.t t/op/assignwarn.t --- t/pragma/warning.t | 82 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) (limited to 't/pragma/warning.t') diff --git a/t/pragma/warning.t b/t/pragma/warning.t index e69de29bb2..c197f35980 100755 --- a/t/pragma/warning.t +++ b/t/pragma/warning.t @@ -0,0 +1,82 @@ +#!./perl + +BEGIN { + chdir 't' if -d 't'; + @INC = '../lib'; + $ENV{PERL5LIB} = '../lib'; +} + +$| = 1; + +my $tmpfile = "tmp0000"; +my $i = 0 ; +1 while -f ++$tmpfile; +END { unlink $tmpfile if $tmpfile; } + +my @prgs = () ; + +foreach (sort glob("pragma/warn-*")) { + + open F, "<$_" or die "Cannot open $_: $!\n" ; + while () { + last if /^__END__/ ; + } + + { + local $/ = undef; + @prgs = (@prgs, split "\n########\n", ) ; + } + close F ; +} + +undef $/; + +print "1..", scalar @prgs, "\n"; + + +for (@prgs){ + my $switch = ""; + my @temps = () ; + if (s/^\s*-\w+//){ + $switch = $&; + } + my($prog,$expected) = split(/\nEXPECT\n/, $_); + if ( $prog =~ /--FILE--/) { + my(@files) = split(/\n--FILE--\s*([^\s\n]*)\s*\n/, $prog) ; + shift @files ; + die "Internal error test $i didn't split into pairs, got " . + scalar(@files) . "[" . join("%%%%", @files) ."]\n" + if @files % 2 ; + while (@files > 2) { + my $filename = shift @files ; + my $code = shift @files ; + push @temps, $filename ; + open F, ">$filename" or die "Cannot open $filename: $!\n" ; + print F $code ; + close F ; + } + shift @files ; + $prog = shift @files ; + } + open TEST, "| sh -c './perl $switch' >$tmpfile 2>&1"; + print TEST $prog, "\n"; + close TEST; + my $status = $?; + my $results = `cat $tmpfile`; + $results =~ s/\n+$//; + $expected =~ s/\n+$//; + my $prefix = ($results =~ s/^PREFIX\n//) ; + if ( $results =~ s/^SKIPPED\n//) { + print "$results\n" ; + } + elsif (($prefix and $results !~ /^\Q$expected/) or + (!$prefix and $results ne $expected)){ + print STDERR "PROG: $switch\n$prog\n"; + print STDERR "EXPECTED:\n$expected\n"; + print STDERR "GOT:\n$results\n"; + print "not "; + } + print "ok ", ++$i, "\n"; + foreach (@temps) + { unlink $_ if $_ } +} -- cgit v1.2.1