in reply to Re^2: You won't believe what this regular expression does!
in thread You won't believe what this regular expression does!
Thanks! :)
But please note the second fOO
DB<55> p "hello\nfoo" =~ s/o*(?:\n|\z)/O/gmr; hellOfOO DB<56>
I'm busy right now, but I seem to remember that one could use features for atomic matches...
I'll try later...°
Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery
update
°) nah doesn't help, since it's not a backtracking problem.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: You won't believe what this regular expression does!
by haukex (Archbishop) on Feb 26, 2021 at 08:26 UTC | |
by salva (Canon) on Feb 26, 2021 at 11:55 UTC | |
by haukex (Archbishop) on Feb 26, 2021 at 13:16 UTC | |
by LanX (Saint) on Feb 26, 2021 at 13:17 UTC | |
by salva (Canon) on Feb 26, 2021 at 14:23 UTC |
In Section
Seekers of Perl Wisdom