in reply to Re: Invert grep match with qr// variable
in thread Invert grep match with qr// variable
- .* should be (?s:.*?).
- Without /s, it could affect whether some strings match or not.
- Without the non-greedy, it will affect the value of capture vars ($&, $1, etc) on a match. Not relevant in this case.
- ^ should be be \G
- This will affect the number of matches when /g is used. Not relevant in this case.