def visit_regex(self, regex, (tilde, literal, flags, _)):
        flags = flags.text.upper()
        pattern = literal.literal  # Pull the string back out of the Literal
                                   # object.
        return Regex(pattern, ignore_case='I' in flags,
                              locale='L' in flags,
                              multiline='M' in flags,
                              dot_all='S' in flags,
                              unicode='U' in flags,
                              verbose='X' in flags)
Return a ``Regex`` expression.
dataset/ETHPy150Open erikrose/parsimonious/parsimonious/grammar.py/RuleVisitor.visit_regex