Folks,

I have this little bit of code that was recommended by Peter Scott (not the
actual code, but he recommended using a SWITCH)

       if ($test = /($regex)/o) {
           SWITCH: for ($test){ # I think this is the problem right here,
not sure though
                 if ( /Communication/ )  {
                      $results{$test}++ if ( $_ =~ /$test/ && $_ =~
/failure/);
                 }

                 if ( /Bind/ ) {
                      $results{$test}++ if ($_ =~ /$test/ && $_ =~ /Factory/
&& $_ =~ /failed/);
                 }

                 if ( /SystemException/ )  {
                      $results{$test}++ if($_ =~ /$test/ && $_ !~
/UnsavedChangesError/);
                 }

                 if ( /SystemError/ )  {
                      $results{$test}++ if($_ =~ /$test/ && $_ !~ /foo/);
                 }

                 if ( /ORB/ ) {
                      $results{$test}++ if($_ =~ /$test/ && $_ !~
/UnsavedChangesError/);
                 }

                 $results{$test}++ if /$test/;
           }
       }

can someone point out my errors and give a brief Duh Huh as to why ;)

also, in a previous post I received a reply of "parens around the left
variable" for this

$session =~ (^/\d+/);

why? I see that it works, but not sure why the need for the parens around
$session

Regards,
Ron

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to