Closed ghost closed 7 years ago
Hello, both expressions you gave are the same, but i suppose the second one is meant to be without the middle '-'. This is indeed a bug, the explanation on the right should see that '-' and explain it. If it is seen as an error by the engine in use, the explanation should reflect that, the fix is different per engine.
thanks for the report, fixed.
Hello I noticed that if you use regexp
^[a-z-0-9]+$
to match against "a-2-3" this gives a match, but the reasons on the right sidebox do not accurately explain the match. (nothing explains why the hyphens match )The unescaped "-" that sits in the middle seems to be taken into account as a litteral, this is correct altough some sources say it could also have been considered an error.
Using the regexp
^[a-z\-0-9]+$
also matches, and gives the proper explanation on the rightI believe the "fix" would be to explain this is taken "into account as a literal BUT could be taken as an error" .
Just FYI,