in reply to Look-Arounds in Regexes are Hard
This makes perl only do a lookahead on encountering an 'f' instead of any character, and reduces the need for the /s modifier./^[^f]*(?:f(?!oo)[^f]*)*$end/
It may look more complex, but I've made a habit of unrolling regexp loops, and now it's almost second nature to me.
|
|---|