my $lemma = qr { (?(DEFINE) (?<pretag> \( [a-z] [-0-9a-z,]* \) \s*) (?<tag> \( [a-z]+ \) \s*) (?<arch> \( arch \) \s*) (?<count> \( [0-9]+ \) \s*)) (?&pretag)* (?&count) (?&tag)* (?&arch) (?&tag)* [^;]* (?:; (?! \s* (?:$ | (?&pretag)* (?&count))) [^;]*)* ; \ * }x; s/$lemma//g;
In reply to Re: Removing with regexps
by JavaFan
in thread Removing with regexps
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |