Lines Matching +full:sub +full:- +full:spaces
4 # SPDX-License-Identifier: GPL-2.0
22 escape_symbols = r"([\x21-\x29\x2b-\x2d\x3a-\x40\x5c\x60\x7b-\x7e])"
33 # Temporarily change [0-9]+ type of patterns
34 (re.compile(r"\[0\-9\]\+"), "\xff"),
36 # Temporarily change [\d+-\d+] type of patterns
37 (re.compile(r"\[0\-\d+\]"), "\xff"),
41 # Temporarily change [0-9] type of patterns
42 (re.compile(r"\[(\d)\-(\d)\]"), "\xf4\1-\2\xf5"),
56 (re.compile(r"([^A-Z])[XYZ]([^A-Z])"), "\\1\\\\w\xf7\\2"),
57 (re.compile(r"([^A-Z])[XYZ]$"), "\\1\\\\w\xf7"),
60 # Recover [0-9] type of patterns
64 # Remove duplicated spaces
76 (re.compile(r"(\d+)\\(-\d+)"), r"\1\2"),
94 re_symbol_name = re.compile(r"(\w|\\[\.\-\:])+$")
151 may match it, based on the sub-groups created by regex_append()
211 new = r.sub(s, new)
214 raise re.PatternError(f"{e}\nwhile re.sub('{r.pattern}', {s}, str)") from e
219 self.log.debug("%-90s <== %s", new, what)