in reply to RFC: Defined-Or for before Perl 5.10
Note that if you want to go the subroutine way, you could also do:
use List::Util qw[first]; my $val = first {defined} undef, 0;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: RFC: Defined-Or for before Perl 5.10
by molecules (Monk) on Oct 29, 2010 at 18:03 UTC | |
by eyepopslikeamosquito (Archbishop) on Oct 30, 2010 at 05:42 UTC | |
by JavaFan (Canon) on Oct 30, 2010 at 07:40 UTC | |
by Tux (Canon) on Oct 30, 2010 at 08:43 UTC | |
|
Re^2: RFC: Defined-Or for before Perl 5.10
by Anonymous Monk on Oct 29, 2010 at 18:28 UTC |