in reply to multiple backreferences in a substitution
I do not understand the question, you mean that this (removing the repeat-while loop) does not work for you?
Or do you mean you want to make it work for multi class stuff like: <span class="foo bar">lorem</span># repeat { # Replace class with inline styles (repeatedly) $new ~~ s/ class \= \" (\w+) \" / style="%classes{ $0.Str }" /; # } while $new ~~ / class \= \" (\w+) \" /;
|
|---|