Hi Kristis,

I have no idea if that could be rewritten in more elegant way. All the
examples which I've searched through Internet and within Bugzilla code are
using $_. The whole { $_ eq '' } expression is kind of lambda function with
single argument.

Regards,
Yavor

On Sat, Mar 5, 2011 at 16:56, Kristis Makris <[email protected]> wrote:

> On Sat, 2011-03-05 at 09:05 +0200, Yavor Nikolov wrote:
> > Hi Kristis,
> >
> > Bugzilla 4.0 has dropped lsearch as per the Release Notes
> > (http://www.bugzilla.org/releases/4.0/release-notes.html):
> >         The Bugzilla::Util::lsearch function is gone. Use firstidx
> >         from List::MoreUtils, instead.
>
> Thank you.
>
> >
> >         -        my $pos = Bugzilla::Util::lsearch($resolution_values,
> >         '');
> >         +        my $pos = firstidx { $_ eq '' } @$resolution_values;
>
> Can this be written without using "$_" ?
>
>
>
>
_______________________________________________
scmbug-users mailing list
[email protected]
http://lists.mkgnu.net/cgi-bin/mailman/listinfo/scmbug-users

Reply via email to