That's an interesting use of qr// to escape out the individual parts, instead of using logic involving \Q..\E. I like the idea, since it avoids the confusion of escape chars in strings vs. in regex, and multiple levels of escaping. I'll be sure to remember that.