From a8d186092f3d0e6f0f1cacf08a0b58b285b23875 Mon Sep 17 00:00:00 2001 From: Eshel Yaron Date: Thu, 29 Sep 2022 20:46:51 +0300 Subject: [PATCH] ENHANCED: More indicative error on failure to locate sweep-module --- sweeprolog.el | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/sweeprolog.el b/sweeprolog.el index 1f03c2c..a759ce4 100644 --- a/sweeprolog.el +++ b/sweeprolog.el @@ -149,7 +149,12 @@ inserted to the input history in `sweeprolog-top-level-mode' buffers." " -t" " halt")) "\n"))))) - (load sweep-module-path))) + (condition-case _ + (load sweep-module-path) + (file-error (user-error + (concat "Failed to locate `sweep-module'. " + "Make sure SWI-Prolog is installed " + "and up to date")))))) (defface sweeprolog-debug-prefix-face '((default :inherit shadow)) -- 2.39.5