diff options
| author | Noam Postavsky | 2017-04-19 23:01:43 -0400 |
|---|---|---|
| committer | Noam Postavsky | 2017-04-19 23:11:44 -0400 |
| commit | 4364a769b489c044c4e9eeac6cfbabcc844ab332 (patch) | |
| tree | b19fdb488f597a80dc6010b19c9413d68d8a8d9b | |
| parent | cd56490fef9cf585708b9d11de2f3f2ec1e2d5b2 (diff) | |
| download | emacs-4364a769b489c044c4e9eeac6cfbabcc844ab332.tar.gz emacs-4364a769b489c044c4e9eeac6cfbabcc844ab332.zip | |
Don't register "def" as an autoload prefix (Bug#26412)
* lisp/emacs-lisp/autoload.el (autoload--make-defs-autoload): Don't
accept "def" as a prefix.
| -rw-r--r-- | lisp/emacs-lisp/autoload.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/autoload.el b/lisp/emacs-lisp/autoload.el index 90e6aec4e75..ca46f317677 100644 --- a/lisp/emacs-lisp/autoload.el +++ b/lisp/emacs-lisp/autoload.el | |||
| @@ -547,7 +547,9 @@ Don't try to split prefixes that are already longer than that.") | |||
| 547 | ;; "cc-helper" and "c-mode", you'll get "c" in the root prefixes. | 547 | ;; "cc-helper" and "c-mode", you'll get "c" in the root prefixes. |
| 548 | (dolist (pair (prog1 prefixes (setq prefixes nil))) | 548 | (dolist (pair (prog1 prefixes (setq prefixes nil))) |
| 549 | (let ((s (car pair))) | 549 | (let ((s (car pair))) |
| 550 | (if (or (> (length s) 2) ;Long enough! | 550 | (if (or (and (> (length s) 2) ; Long enough! |
| 551 | ;; But don't use "def" from deffoo-pkg-thing. | ||
| 552 | (not (string= "def" s))) | ||
| 551 | (string-match ".[[:punct:]]\\'" s) ;A real (tho short) prefix? | 553 | (string-match ".[[:punct:]]\\'" s) ;A real (tho short) prefix? |
| 552 | (radix-tree-lookup (cdr pair) "")) ;Nothing to expand! | 554 | (radix-tree-lookup (cdr pair) "")) ;Nothing to expand! |
| 553 | (push pair prefixes) ;Keep it as is. | 555 | (push pair prefixes) ;Keep it as is. |