my $is_success = 0; BLOCK: { function1() or last BLOCK; function2() or last BLOCK; require Foo; Foo::bar() or last BLOCK; function3() or last BLOCK; # etc; $is_success = 1; } if ($is_success) { print "All done\n"; } else { print "FAILED\n"; }