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

Re: [perl #109798] '/e' regexp modifier is not recognized by re pragma

Thread Previous | Thread Next
From:
Tom Christiansen
Date:
February 6, 2012 03:49
Subject:
Re: [perl #109798] '/e' regexp modifier is not recognized by re pragma
Message ID:
15339.1328528933@chthon
Paul Johnson <paul@pjcj.net> wrote
   on Mon, 06 Feb 2012 12:42:42 +0100: 
>On Mon, Feb 06, 2012 at 04:18:38AM -0700, Tom Christiansen wrote:
>> >I do wonder if this is intentional or an interesting implementation s<SNIP>
>> 
>> It's been that way since time immemorial, but I can no longer
>> recall whether it was initially done by intent.  

>And it's seen far less frequently nowadays.  Back then we had a general
>tendency to be a little more cavalier in such matters.

What, /ee?  It's the normal way to get single variables interpolated.

A single /e is like an eval { }, and compiled at compile time.
A double /e is more like an eval "", and gets compiled at run time.

But I never much go beyond that, because that's writing
eval eval foo().

--tom

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