John Deighan wrote:
The problem with trying to use goto, or a return, or setting a global
variable is that they don't work well in a function that's being called
by the code that contains the eval. 'return' won't work because it will
simply return from the function that was called.
No it doesn't. Have you even tried it?
#!/usr/bin/perl
sub foo {
my $ret = eval {
return 1;
};
print "ret = $ret$/";
return 2;
}
print "Foo returns ", foo(), $/;
__END__
output is:
ret = 1
Foo returns 2
Rhesa
_______________________________________________
Perl-Win32-Users mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs