The only caveat i can think of is that if the $arrayref got set to an empty arrayref, i'd still not want to do the if conditional (in this situation). So i think the final will be:
which will throw an exception if its not an arrayref.if ( $arrayref && @$arrayref ) {
In reply to Re^2: Using undef scalar as arrayref
by shemp
in thread Using undef scalar as arrayref
by shemp
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |