There is no benefit to studying a string more than once.
Just as a matter of curiosity, have you ever come across a case in which there was a benefit from studying a string even once?
Occasionally and informally, I have Benchmark-ed a use of study that I thought might be beneficial per the description in the docs: matching many regexes against a single, unchanging string. I have never seen any benefit. (I must admit I have never tested the specific example given in the perlfunc docs for which a potential "big win" is claimed.) Has regex optimization reached a point at which we can say "... I ain't gonna study [strings] no more"?
In reply to Re^2: counting the number of 16384 pattern matches in a large DNA sequence
by AnomalousMonk
in thread counting the number of 16384 pattern matches in a large DNA sequence
by anonym
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |