aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEshel Yaron2025-10-12 17:09:36 +0200
committerEshel Yaron2025-10-12 17:09:36 +0200
commit07505fd6c5e32f52efe2ef3237a0ee8ecdfac39b (patch)
tree43095aac588b8380f7fa42033c84fb4c581c42ac
parent81867057529af488bfc1dde66581f2d546ac42f0 (diff)
downloademacs-07505fd6c5e32f52efe2ef3237a0ee8ecdfac39b.tar.gz
emacs-07505fd6c5e32f52efe2ef3237a0ee8ecdfac39b.zip
; elisp-scope.el: Improve customization group name handling.
* lisp/emacs-lisp/elisp-scope.el (elisp-scope-quoted-group): Delete it. (define-minor-mode, define-derived-mode): Simplify analyzers.
-rw-r--r--lisp/emacs-lisp/elisp-scope.el12
1 files changed, 2 insertions, 10 deletions
diff --git a/lisp/emacs-lisp/elisp-scope.el b/lisp/emacs-lisp/elisp-scope.el
index 1ccf32324de..5933a92745f 100644
--- a/lisp/emacs-lisp/elisp-scope.el
+++ b/lisp/emacs-lisp/elisp-scope.el
@@ -1239,13 +1239,6 @@ Optional argument LOCAL is a local context to extend."
1239 (elisp-scope-report 'deftype beg (length (symbol-name bare)))) 1239 (elisp-scope-report 'deftype beg (length (symbol-name bare))))
1240 (elisp-scope-lambda args body)) 1240 (elisp-scope-lambda args body))
1241 1241
1242(defun elisp-scope-quoted-group (sym-form)
1243 (when-let* (((eq (elisp-scope-sym-bare (car-safe sym-form)) 'quote))
1244 (sym (cadr sym-form))
1245 (beg (elisp-scope-sym-pos sym))
1246 (bare (elisp-scope-sym-bare sym)))
1247 (elisp-scope-report 'group beg (length (symbol-name bare)))))
1248
1249(defun elisp-scope-defmethod-1 (local args body) 1242(defun elisp-scope-defmethod-1 (local args body)
1250 (if args 1243 (if args
1251 (let ((arg (car args)) (bare nil)) 1244 (let ((arg (car args)) (bare nil))
@@ -1566,8 +1559,7 @@ Optional argument LOCAL is a local context to extend."
1566 (elisp-scope-sharpquote tail)) 1559 (elisp-scope-sharpquote tail))
1567 (elisp-scope-1 place))) 1560 (elisp-scope-1 place)))
1568 (setq explicit-var t)) 1561 (setq explicit-var t))
1569 ((:group) 1562 ((:group) (elisp-scope-1 (cadr body) '(symbol . group)))
1570 (elisp-scope-quoted-group (cadr body)))
1571 ((:predicate) ;For globalized minor modes. 1563 ((:predicate) ;For globalized minor modes.
1572 (elisp-scope-global-minor-mode-predicate (cadr body))) 1564 (elisp-scope-global-minor-mode-predicate (cadr body)))
1573 ((:on :off) 1565 ((:on :off)
@@ -2273,7 +2265,7 @@ property, or if the current buffer is trusted (see `trusted-content-p')."
2273 ((keywordp bkw))) 2265 ((keywordp bkw)))
2274 (elisp-scope-report-s kw 'constant) 2266 (elisp-scope-report-s kw 'constant)
2275 (cl-case bkw 2267 (cl-case bkw
2276 (:group (elisp-scope-quoted-group (cadr body))) 2268 (:group (elisp-scope-1 (cadr body) '(symbol . group)))
2277 ((:syntax-table :abbrev-table :after-hook) (elisp-scope-1 (cadr body)))) 2269 ((:syntax-table :abbrev-table :after-hook) (elisp-scope-1 (cadr body))))
2278 (setq body (cddr body))) 2270 (setq body (cddr body)))
2279 (elisp-scope-n body)) 2271 (elisp-scope-n body))