You don't say why you find the goto version more attractive. I guess because of the separate declaration and initialization of $status. However:
my $status; do { $status = getstore (ask_url (), $file); } while $status == 200 && !-s $file && --$max_tries > 0;
makes it clear that there is a loop involved and what the conditions on the loop are. Having $status declared outside the loop makes it clear that $status is required after the loop has terminated.
In reply to Re^3: GOTO or not GOTO
by GrandFather
in thread GOTO or not GOTO
by jflevi
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |