vit has asked for the wisdom of the Perl Monks concerning the following question:
will $re be precompiled and therefore not changed only within one loop iteration and on the next one be recompiled again since $re is declared inside loop?foreach(...) { my $re=qr/...$xxx..../o; @a = grep { /$re/ } @b ..... }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Precompiling qr/.../o question
by leocharre (Priest) on Apr 02, 2008 at 13:50 UTC | |
|
Re: Precompiling qr/.../o question
by jwkrahn (Abbot) on Apr 02, 2008 at 13:27 UTC | |
|
Re: Precompiling qr/.../o question
by ikegami (Patriarch) on Apr 02, 2008 at 19:35 UTC | |
by ikegami (Patriarch) on Apr 08, 2008 at 04:43 UTC | |
|
Re: Precompiling qr/.../o question
by hardburn (Abbot) on Apr 02, 2008 at 13:36 UTC | |
by mr_mischief (Monsignor) on Apr 02, 2008 at 15:28 UTC | |
by hardburn (Abbot) on Apr 02, 2008 at 19:11 UTC | |
by mr_mischief (Monsignor) on Apr 02, 2008 at 21:52 UTC | |
by ack (Deacon) on Apr 04, 2008 at 17:21 UTC | |
by mr_mischief (Monsignor) on Apr 04, 2008 at 17:31 UTC | |
by ack (Deacon) on Apr 08, 2008 at 03:52 UTC | |
| |
|
Re: Precompiling qr/.../o question
by zentara (Cardinal) on Apr 02, 2008 at 17:28 UTC | |
|
Re: Precompiling qr/.../o question
by locked_user sundialsvc4 (Abbot) on Apr 03, 2008 at 13:50 UTC | |
by ikegami (Patriarch) on Apr 08, 2008 at 04:28 UTC |