boolean return (was Re: cpan you have to see)
Mark Overmeer
mark at overmeer.net
Wed Dec 12 21:52:55 GMT 2012
* Abigail (abigail at abigail.be) [121212 21:38]:
> The flip side of this dogma is, you end up with code like:
>
> sub foo {
> ...
> return unless $result;
> return $result;
> }
sub foo {
...
$result || (); # $result // ();
}
Suitable for list-filters only.
--
MarkOv
------------------------------------------------------------------------
Mark Overmeer MSc MARKOV Solutions
Mark at Overmeer.net solutions at overmeer.net
http://Mark.Overmeer.net http://solutions.overmeer.net
More information about the london.pm
mailing list