in reply to Re: Re^7: Grep Pattern Match
in thread Grep Pattern Match
Oh but that's not at all the same. It's quite obvious (to me anyway) that $count is being compiled each time. The only reason I brought this up was I didn't know whether the invariant regex in a block attacked to a grep was going to be recompiled each time or not. There's an opportunity for perl to notice that the regex only needs to compiled once - the question here is on whether it takes it or not.
Update: Oops! I thought you said $line =~ $count where you actually said $line =~ $regex. Anyhow I still think you've misunderstood which question I was asking.
Fun Fun Fun in the Fluffy Chair
|
|---|