diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 2000-02-25 19:23:58 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 2000-02-25 19:23:58 +0000 |
commit | 1ba6ee2b6ffb90b7d229bcee46bded6dda6b3bcc (patch) | |
tree | a13a13beae8049211a412cce5206dccd24673251 /t | |
parent | faee740f668b7b35a18577bc0b2150b66dd521ec (diff) | |
download | perl-1ba6ee2b6ffb90b7d229bcee46bded6dda6b3bcc.tar.gz |
change#4849 wasn't restoring savestack correctly; make loops that have
continue blocks recognizable at run time
p4raw-link: @4849 on //depot/perl: 872465582bf743a066e1240f2c3e941735674827
p4raw-id: //depot/perl@5255
Diffstat (limited to 't')
-rwxr-xr-x | t/cmd/while.t | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/t/cmd/while.t b/t/cmd/while.t index 46bbdea15a..ecc15eda53 100755 --- a/t/cmd/while.t +++ b/t/cmd/while.t @@ -1,6 +1,6 @@ #!./perl -print "1..19\n"; +print "1..22\n"; open (tmp,'>Cmd_while.tmp') || die "Can't create Cmd_while.tmp."; print tmp "tvi925\n"; @@ -160,3 +160,20 @@ print "ok $i\n"; print "ok $l\n" } } + +$i = 20; +{ + while (1) { + my $x; + print $x if defined $x; + $x = "not "; + print "ok $i\n"; ++$i; + if ($i == 21) { + next; + } + last; + } + continue { + print "ok $i\n"; ++$i; + } +} |