From c96c89faaa02a2ff76ec30146ba466aece622603 Mon Sep 17 00:00:00 2001 From: Daniel Mendler Date: Sun, 22 Mar 2026 10:58:40 -0400 Subject: [PATCH] (dabbrev-completion): Improve last fix for bug#80645 * lisp/dabbrev.el (dabbrev-completion): Signal the error that `dabbrev-capf` doesn't signal any more. --- lisp/dabbrev.el | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/dabbrev.el b/lisp/dabbrev.el index 0e3c8bf6a5f..9fe2904c415 100644 --- a/lisp/dabbrev.el +++ b/lisp/dabbrev.el @@ -398,7 +398,11 @@ then it searches *all* buffers." ;; Set it so `dabbrev-capf' won't reset the vars. (setq dabbrev--last-abbrev-location (point-marker)) (let ((completion-at-point-functions '(dabbrev-capf))) - (completion-at-point))) + (unless (completion-at-point) + (user-error "No dynamic expansion for \"%s\" found%s" + (dabbrev--abbrev-at-point) + (if dabbrev--check-other-buffers + "" " in this-buffer"))))) (defun dabbrev-capf () "Dabbrev completion function for `completion-at-point-functions'."