mirror of
https://github.com/James-Yu/LaTeX-Workshop.git
synced 2024-10-05 07:37:24 +03:00
fix regex.
This commit is contained in:
parent
492b0fad45
commit
e1ce812507
@ -51,8 +51,8 @@ def parse_unimathsymbols_file() -> Dict[str, Dict[str, str]]:
|
||||
cmds.append(re.sub(r'^\\', '', arry[3]))
|
||||
for m in re.finditer(r'= \\(\w+)[ ,]', arry[-1]):
|
||||
cmds.append(m.group(1))
|
||||
doc = re.sub(r'\s*[\=#xt]\s*\\\w+(\{.*?\})?\s*(\(.*?\))?\s*,', '', arry[-1])
|
||||
doc = re.sub(r'\s*[\=#xt]\s*\S+\s*,', '', doc)
|
||||
doc = re.sub(r'\s*[=#xt]\s*\\\w+(\{.*?\})?\s*(\(.*?\))?\s*,', '', arry[-1])
|
||||
doc = re.sub(r'\s*[=#xt]\s*\S+\s*,', '', doc)
|
||||
doc = doc.strip()
|
||||
for c in cmds:
|
||||
if c == '' or re.search('{', c):
|
||||
|
Loading…
Reference in New Issue
Block a user