From a6b41a817e8d760ab3be417779f4c0e36fa1160e Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 23 Dec 2019 23:47:54 -0500 Subject: [PATCH] * src/minibuf.c (read_minibuf): Use `user-error` --- src/minibuf.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/minibuf.c b/src/minibuf.c index f8790f55070..7b17e7dc05b 100644 --- a/src/minibuf.c +++ b/src/minibuf.c @@ -414,12 +414,13 @@ read_minibuf (Lisp_Object map, Lisp_Object initial, Lisp_Object prompt, if (!enable_recursive_minibuffers && minibuf_level > 0) { + Lisp_Object str = build_string ("Command attempted to use minibuffer" + "while in minibuffer"); if (EQ (selected_window, minibuf_window)) - error ("Command attempted to use minibuffer while in minibuffer"); + Fsignal (Quser_error, (list1 (str))); else /* If we're in another window, cancel the minibuffer that's active. */ - Fthrow (Qexit, - build_string ("Command attempted to use minibuffer while in minibuffer")); + Fthrow (Qexit, str); } if ((noninteractive -- 2.39.2