This question has turned into a rollback war which I did not expect. I kept doing rollback to remove regex tag and the other user kept adding it.
- I'm 99% sure that I'm doing the right thing, see below for detailed explanation.
- From Put an end to rollback wars, a "rollback war" auto-flag should have been generated for moderator attention. If I understand it correctly, a custom flag isn't necessary, right?
- I'm sure the other editor and I both believe we are doing the right thing, but the rollback war isn't helping. I left a comment to further explain what I'm doing since the second rollback, but it seems that the comments are not helping, either.
My main question is, how to stop this rollback war?
There are quite a few questions in lua about pattern matching which are tagged with regex in the first place, and people kindly answered these questions with a regex solution. However, in most cases, the OP found out that these regexes don't solve their problems. That is because
Lua pattern isn't regex!
Programming in Lua explains why Lua doesn't have a native regex support like many other languages. Plus, people that like to find a more powerful pattern matching often choose LPeg, a library based on Parsing Expression Grammars, written by Roberto Ierusalimschy, one of Lua's authors.
As a simple example, you might expect (ab)+
to match one or more repetitions of ab
. However, in Lua pattern matching, +
applies to one character only.
There are questions that could be tagged with both lua and regex:
- Questions that discuss the difference between Lua pattern and regex.
- Questions that use a third party regex library.
However, in most cases, it turned out that the OP doesn't know Lua pattern isn't regex, and tagged the question with the wrong tag.
pcre
to also be taggedregex
, becausepcre
is a superset of regular expressions. (And more widely available). But on the general point - it takes two to tango. Stop playing, and flag it for a mod.