branch: master
commit a5599695b0db2fedc895460d10a6cd136f082962
Author: Arash Esbati <[email protected]>
Commit: Arash Esbati <[email protected]>
Save regexp groups
* style/xparse.el (LaTeX-xparse-macro-regexp)
(LaTeX-xparse-environment-regexp): Use shy groups where possible.
---
style/xparse.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/style/xparse.el b/style/xparse.el
index e71e456d..f3feaa56 100644
--- a/style/xparse.el
+++ b/style/xparse.el
@@ -57,7 +57,7 @@
"[ \t\n\r]*"
"}?"
"[ \t\n\r]*"
-
"{\\([^}{]*\\({[^}{]*\\({[^}{]*\\({[^}{]*}[^}{]*\\)*}[^}{]*\\)*}[^}{]*\\)*\\)}")
+
"{\\([^}{]*\\(?:{[^}{]*\\(?:{[^}{]*\\(?:{[^}{]*}[^}{]*\\)*}[^}{]*\\)*}[^}{]*\\)*\\)}")
(0 2 3 1) LaTeX-auto-xparse-macro)
"Matches macros by xparse package.")
@@ -75,7 +75,7 @@
"[ \t\n\r]*"
"}"
"[ \t\n\r]*"
-
"{\\([^}{]*\\({[^}{]*\\({[^}{]*\\({[^}{]*}[^}{]*\\)*}[^}{]*\\)*}[^}{]*\\)*\\)}")
+
"{\\([^}{]*\\(?:{[^}{]*\\(?:{[^}{]*\\(?:{[^}{]*}[^}{]*\\)*}[^}{]*\\)*}[^}{]*\\)*\\)}")
(0 2 3 1) LaTeX-auto-xparse-environment)
"Matches environments by xparse package.")