in reply to Re^4: Switch.pm Failure
in thread Switch.pm Failure

Ya know, this kinda reeks of hand converting some other language into perl the hard way. the whole (logical-test) && do { process-stmts} ; setup while legal is very "un-perlish". with the liberal use if return (to return from Main) a more perl-like sequence would be

if (logical-test1) { process-stmts1; return; } if (logical-test2) { process-stmts2; return; } ...
or without the returns
if (test1) { process-stmts1; } elsif (test2) { process-stmts2; } ...
or in modern perls the given/when structure as in http://perldoc.perl.org/perlsyn.html#Switch-Statements

it reminds me of the time i saw a guy translate fortran into sas by coding it all inside a single "do while(1)" statement rather than 3 simpler data steps.