The problem with regex is multi-language support and how big the regex will bloat if you to support even 10 languages.
We're talking about Claude Code. If you're coding and not writing or thinking in English, the agents and people reading that code will have bigger problems than a regexp missing a swear word :).
They only need to look at one language to get a statistically meaningful picture into common flaws with their model(s) or application.
If they want to drill down to flaws that only affect a particular language, then they could add a regex for that as well/instead.
Did you just complain about bloat, in anything using npm?
Supporting 10 different languages in regex is a drop in the ocean. The regex can be generated programmatically and you can compress regexes easily. We used to have a compressed regex that could match any placename or street name in the UK in a few MB of RAM. It was silly quick.