develooper Front page | perl.perl5.porters | Postings from May 2012

Re: proposal: functional C<if>

Thread Previous | Thread Next
From:
Eric Brine
Date:
May 1, 2012 12:55
Subject:
Re: proposal: functional C<if>
Message ID:
CALJW-qFfD3vWgE_cLYzgmYteS6aFCjCy+LOv+ak29AViEXL8pw@mail.gmail.com
On Tue, May 1, 2012 at 3:53 PM, Eric Brine <ikegami@adaelis.com> wrote:

> On Tue, May 1, 2012 at 11:24 AM, David Nicol <davidnicol@gmail.com> wrote:
>
>> On Tue, May 1, 2012 at 10:11 AM, Paul LeoNerd Evans
>> <leonerd@leonerd.org.uk> wrote:
>> > At which point we might consider what
>> >
>> >  my @values = (while($cond) { EXPR });
>> >
>> > might do.
>> >
>> > Just a thought...
>>
>> it seems clear that @values would wind up holding one of undef, 0, '',
>> or some overloaded reference that gives a false value in boolean
>> context..
>>
>
> It does not seem clear to me at all. Why would Perl do something useless?
> I would expect a warning if not an error
>

...if some useful behaviour can't be found, that is.


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About