From f9e14d72b466f9d8ad54bef69f23d168e91c6946 Mon Sep 17 00:00:00 2001 From: djcb Date: Tue, 11 Sep 2012 22:47:58 +0300 Subject: [PATCH] * mu4e: only use user-error if it exists (i.e.., emacs trunk); otherwise user (error..) it'd be nice to have something like user-error in emacs 24, 23, i.e., like error but without triggering the debugger --- mu4e/mu4e-utils.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mu4e/mu4e-utils.el b/mu4e/mu4e-utils.el index 3a565b2c..6971d6f4 100644 --- a/mu4e/mu4e-utils.el +++ b/mu4e/mu4e-utils.el @@ -112,7 +112,9 @@ a local-exit and does not return." "Create [mu4e]-prefixed warning based on format FRM and ARGS. Does a local-exit and does not return." (mu4e-log 'error (apply 'mu4e-format frm args)) - (user-error "%s" (apply 'mu4e-format frm args))) + (if (fboundp 'user-error) + (user-error "%s" (apply 'mu4e-format frm args)) ;; only in emacs-trunk + (error "%s" (apply 'mu4e-format frm args)))) (defun mu4e~read-char-choice (prompt choices) "Compatiblity wrapper for `read-char-choice', which is emacs-24