Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Re: Interpolated code blocks may not create lexicals

0 views
Skip to first unread message

David Nicol

unread,
Sep 25, 2008, 4:08:21 PM9/25/08
to Eirik Berg Hanssen, David Landgren, f...@perl.org
On 9/25/08, Eirik Berg Hanssen <Eirik-Ber...@allverden.no> wrote:
> print <<STR;
> I like @{
> my $rand = rand();
> [$rand < 0.5 ? 'pie' : 'beer']
> }
> STR
>
>
> You already have a block; no need for a do-block within it.
>
>
> (The rest, others already covered.)

the "fun with perl" mailing list doesn't still exist, does it?

there's also

my $BeerOrPie;
sub BeerOrPie::TIESCALAR { bless \(my $x), 'BeerOrPie' };
sub BeerOrPie::FETCH { rand() < 0.5 ? 'pie' : 'beer'; };
tie $BeerOrPie, 'BeerOrPie';
print "I like $BeerOrPie\n";

--
"checks and balances" is not financial jargon

Richard Hartmann

unread,
Sep 28, 2008, 7:07:01 PM9/28/08
to Michael G Schwern, David Nicol, Eirik Berg Hanssen, David Landgren, f...@perl.org
On Sat, Sep 27, 2008 at 00:04, Michael G Schwern <sch...@pobox.com> wrote:
> David Nicol wrote:
>> the "fun with perl" mailing list doesn't still exist, does it?
>
> Yes, yes it does.

Lies! It does not!


Richard

Ryan Yagatich

unread,
Sep 29, 2008, 8:01:54 AM9/29/08
to Richard Hartmann, Michael G Schwern, David Nicol, Eirik Berg Hanssen, David Landgren, f...@perl.org
Oh Noes!

Regards,
Ryan Yagatich

--
\|||/
---------0oo------( o o )------oo0----------
Ryan Yagatich (_) ryag...@gmail.com
http://www.linkedin.com/in/yagatich
-----------------------------------------


0 new messages