emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/typescript-mode a1cdb7a1ec 121/222: Remove redundant regex


From: ELPA Syncer
Subject: [nongnu] elpa/typescript-mode a1cdb7a1ec 121/222: Remove redundant regexp groups for jsdoc tags
Date: Sun, 6 Feb 2022 16:59:25 -0500 (EST)

branch: elpa/typescript-mode
commit a1cdb7a1ec626b3a72684c7ad74231a6742f4e68
Author: Ailrun <jjc9310@gmail.com>
Commit: Junyoung Clare Jang <jjc9310@gmail.com>

    Remove redundant regexp groups for jsdoc tags
---
 typescript-mode.el | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/typescript-mode.el b/typescript-mode.el
index ff1d1539e0..9d2ef766bc 100644
--- a/typescript-mode.el
+++ b/typescript-mode.el
@@ -439,7 +439,7 @@ Match group 1 is MUMBLE.")
 ;; and extended with tags in http://usejsdoc.org/
 (defconst typescript-jsdoc-typed-tag-regexp
   (concat typescript-jsdoc-before-tag-regexp
-          "\\(@\\(?:"
+          "\\(@"
           (regexp-opt
            '("enum"
              "extends"
@@ -456,14 +456,14 @@ Match group 1 is MUMBLE.")
              "type"
              "yield"
              "yields"))
-          "\\)\\)\\s-*\\({[^}]+}\\)?")
+          "\\)\\s-*\\({[^}]+}\\)?")
   "Matches jsdoc tags with optional type.")
 
 ;; This was taken from js2-mode.
 ;; and extended with tags in http://usejsdoc.org/
 (defconst typescript-jsdoc-arg-tag-regexp
   (concat typescript-jsdoc-before-tag-regexp
-          "\\(@\\(?:"
+          "\\(@"
           (regexp-opt
            '("access"
              "alias"
@@ -500,14 +500,14 @@ Match group 1 is MUMBLE.")
              "var"
              "variation"
              "version"))
-          "\\)\\)\\s-+\\([^ \t]+\\)")
+          "\\)\\s-+\\([^ \t]+\\)")
   "Matches jsdoc tags with a single argument.")
 
 ;; This was taken from js2-mode
 ;; and extended with tags in http://usejsdoc.org/
 (defconst typescript-jsdoc-empty-tag-regexp
   (concat typescript-jsdoc-before-tag-regexp
-          "\\(@\\(?:"
+          "\\(@"
           (regexp-opt
            '("abstract"
              "addon"
@@ -567,7 +567,7 @@ Match group 1 is MUMBLE.")
              "todo"
              "tutorial"
              "virtual"))
-          "\\)\\)\\s-*")
+          "\\)\\s-*")
   "Matches empty jsdoc tags.")
 
 ;; Note that this regexp by itself would match tslint flags that appear inside



reply via email to

[Prev in Thread] Current Thread [Next in Thread]