Closed marcotcr closed 1 year ago
Python regex has a bug such that the following code return (False, False):
import pyformlang import pyformlang.regular_expression r = pyformlang.regular_expression.PythonRegex('.*') r.accepts(']'),r.accepts('\\')
The problem is that '\' is in list(string.printable), and thus you have to escape it (otherwise it messes up the join). This PR fixes the above.
Thank you for your contribution! I will add a new test with your example.
Python regex has a bug such that the following code return (False, False):
The problem is that '\' is in list(string.printable), and thus you have to escape it (otherwise it messes up the join). This PR fixes the above.