From: Joseph Turner <joseph@breatheoutbreathe.in>
To: Emacs Devel Mailing List <emacs-devel@gnu.org>
Subject: [PATCH] project.el: Use list of strings p for safe local variable
Date: Fri, 25 Aug 2023 21:38:50 -0700 [thread overview]
Message-ID: <87r0nqct63.fsf@breatheoutbreathe.in> (raw)
[-- Attachment #1: Type: text/plain, Size: 43 bytes --]
Might make sense to merge this into 29.2?
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-project.el-Use-list-of-strings-p-for-safe-local-vari.patch --]
[-- Type: text/x-diff, Size: 1587 bytes --]
From 8237eb21c81b3e5ededd42a3a2d5b9770d45ca92 Mon Sep 17 00:00:00 2001
From: Joseph Turner <joseph@breatheoutbreathe.in>
Date: Fri, 25 Aug 2023 21:31:06 -0700
Subject: [PATCH] project.el: Use list-of-strings-p for safe-local-variable
predicate
* lisp/progmodes/project.el (project-vc-ignores)
(project-vc-extra-root-markers)
---
lisp/progmodes/project.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el
index 8d8bf594628..882173a65d0 100644
--- a/lisp/progmodes/project.el
+++ b/lisp/progmodes/project.el
@@ -397,7 +397,7 @@ the buffer's value of `default-directory'."
(defcustom project-vc-ignores nil
"List of patterns to add to `project-ignores'."
:type '(repeat string))
-;;;###autoload(put 'project-vc-ignores 'safe-local-variable #'listp)
+;;;###autoload(put 'project-vc-ignores 'safe-local-variable #'list-of-strings-p)
(defcustom project-vc-merge-submodules t
"Non-nil to consider submodules part of the parent project.
@@ -452,7 +452,7 @@ variables, such as `project-vc-ignores' or `project-vc-name'."
:type '(repeat string)
:version "29.1"
:package-version '(project . "0.9.0"))
-;;;###autoload(put 'project-vc-extra-root-markers 'safe-local-variable (lambda (val) (and (listp val) (not (memq nil (mapcar #'stringp val))))))
+;;;###autoload(put 'project-vc-extra-root-markers 'safe-local-variable #'list-of-strings-p)
;; FIXME: Using the current approach, major modes are supposed to set
;; this variable to a buffer-local value. So we don't have access to
--
2.41.0
next reply other threads:[~2023-08-26 4:38 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-26 4:38 Joseph Turner [this message]
2023-08-26 11:59 ` [PATCH] project.el: Use list of strings p for safe local variable Stefan Kangas
2023-08-26 12:51 ` Dmitry Gutov
2023-08-30 7:10 ` bug#65608: Fwd: " Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-30 11:22 ` Dmitry Gutov
2023-08-30 17:54 ` Stefan Kangas
2023-08-31 0:30 ` Dmitry Gutov
2023-08-31 6:45 ` Stefan Kangas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87r0nqct63.fsf@breatheoutbreathe.in \
--to=joseph@breatheoutbreathe.in \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.