This construct, legal in Perl 4, has become invalid in perl 5.001l:
% perl -we '$x=1; do { last if $x==1; $x++ } while $x<0'
Can't "last" outside a block at -e line 1.
This is a pity, since 'do {..} while' is the only sane way to get a
minimum-once loop.
Sorry, I didn't check the bug list - www.perl.com wasn't responding.
Ian
% perl -we '$x=1; do { last if $x==1; $x++ } while $x<0'
Can't "last" outside a block at -e line 1.
This is a pity, since 'do {..} while' is the only sane way to get a
minimum-once loop.
Sorry, I didn't check the bug list - www.perl.com wasn't responding.
Ian