From 6ca714f3c8a8379dd896c255b3e12bbc2d7024cd Mon Sep 17 00:00:00 2001 From: Eshel Yaron Date: Sun, 22 Jan 2023 10:20:13 +0200 Subject: [PATCH] don't use file-name-split for compatibility with older Emacsen --- sweeprolog.el | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/sweeprolog.el b/sweeprolog.el index c05cd78..38fe0e0 100644 --- a/sweeprolog.el +++ b/sweeprolog.el @@ -861,12 +861,7 @@ PROJECT (only on Emacs 28 or later)." (when (fboundp 'project-known-project-roots) (car (seq-filter (lambda (root) - (member (car - (reverse - (seq-filter - (lambda (s) - (not (string-empty-p s))) - (file-name-split root)))) + (member (file-name-base (directory-file-name root)) '("swipl" "swipl-devel"))) (project-known-project-roots))))))) -- 2.39.2