From 88dd3c24e898d5f281513b5d31d53e87f46c8278 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 29 Jul 1994 21:35:56 +0000 Subject: [PATCH] (choose-completion): Check for next-single-property-change returning nil. --- lisp/simple.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/simple.el b/lisp/simple.el index 237be507cf1..da837322c8f 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -2491,7 +2491,7 @@ it were the arg to `interactive' (which see) to interactively read the value." (if (null beg) (error "No completion here")) (setq beg (previous-single-property-change beg 'mouse-face)) - (setq end (next-single-property-change end 'mouse-face)) + (setq end (or (next-single-property-change end 'mouse-face) (point-max))) (choose-completion-string (buffer-substring beg end)))) ;; Delete the longest partial match for STRING -- 2.39.5