[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/org 933d282881 3/9: Fix Emacs 27 false-positive warning
From: |
ELPA Syncer |
Subject: |
[elpa] externals/org 933d282881 3/9: Fix Emacs 27 false-positive warnings |
Date: |
Fri, 18 Aug 2023 06:58:29 -0400 (EDT) |
branch: externals/org
commit 933d2828812084ca8f8eff72699dcd025fff88de
Author: Ihor Radchenko <yantar92@posteo.net>
Commit: Ihor Radchenko <yantar92@posteo.net>
Fix Emacs 27 false-positive warnings
* lisp/org-element-ast.el (org-element--plist-property): Shield
annoying warning spam with `with-no-warnings'. The warnings are not
present in newer Emacs.
* lisp/org-element.el (org-element--interpret-affiliated-keywords):
Suppress warning about two token unused `_' arguments.
* lisp/org-id.el (org-id-find-id-in-file): Suppress warning about
number of arguments.
---
lisp/org-element-ast.el | 10 ++++++++--
lisp/org-element.el | 2 +-
lisp/org-id.el | 4 ++--
3 files changed, 11 insertions(+), 5 deletions(-)
diff --git a/lisp/org-element-ast.el b/lisp/org-element-ast.el
index c845be26b4..e829474189 100644
--- a/lisp/org-element-ast.el
+++ b/lisp/org-element-ast.el
@@ -393,12 +393,18 @@ Ignore standard property array."
(`plain-text
(or (get-text-property 0 ,property ,node)
(when ,dflt
- (if (plist-member (text-properties-at 0 ,node) ,property)
+ (if
+ ;; FIXME: Byte-compiler throws false positives in Emacs 27.
+ (with-no-warnings
+ (plist-member (text-properties-at 0 ,node) ,property))
nil ,dflt))))
(_
(or (plist-get (nth 1 ,node) ,property)
(when ,dflt
- (if (plist-member (nth 1 ,node) ,property)
+ (if
+ ;; FIXME: Byte-compiler throws false positives in Emacs 27.
+ (with-no-warnings
+ (plist-member (nth 1 ,node) ,property))
nil ,dflt))))))))
(define-inline org-element-property-raw (property node &optional dflt)
diff --git a/lisp/org-element.el b/lisp/org-element.el
index f197e34a94..69a62a2f5c 100644
--- a/lisp/org-element.el
+++ b/lisp/org-element.el
@@ -5219,7 +5219,7 @@ If there is no affiliated keyword, return the empty
string."
;; cannot belong to the property list.
(let (acc)
(org-element-properties-mapc
- (lambda (prop _ _)
+ (lambda (prop _ __)
(let ((keyword (upcase (substring (symbol-name prop) 1))))
(when (or (string-match-p "^ATTR_" keyword)
(and
diff --git a/lisp/org-id.el b/lisp/org-id.el
index d09c61b066..c11fa9a2d1 100644
--- a/lisp/org-id.el
+++ b/lisp/org-id.el
@@ -678,8 +678,8 @@ optional argument MARKERP, return the position as a new
marker."
(buffer (or visiting
(if markerp (find-file-noselect file)
(if (<= 2 (cdr (func-arity #'get-buffer-create)))
- (get-buffer-create " *Org ID temp*" t)
- ;; Emacs 27 does not yet have second argument.
+ (with-no-warnings (get-buffer-create " *Org ID
temp*" t))
+ ;; FIXME: Emacs 27 does not yet have second
argument.
(get-buffer-create " *Org ID temp*"))))))
(unwind-protect
(with-current-buffer buffer
- [elpa] externals/org updated (d0c7cd48eb -> 83fd03fb6d), ELPA Syncer, 2023/08/18
- [elpa] externals/org 83fd03fb6d 9/9: org-attach: Fix when called from agenda, ELPA Syncer, 2023/08/18
- [elpa] externals/org 3ec0933122 4/9: Fix Emacs 27 test failure, ELPA Syncer, 2023/08/18
- [elpa] externals/org 3b49db8755 1/9: Revert "Prefer `string-search' when matching exact strings", ELPA Syncer, 2023/08/18
- [elpa] externals/org 9e40208547 2/9: test-org-agenda/todo-selector: Remove stray `message' call, ELPA Syncer, 2023/08/18
- [elpa] externals/org 2eb4fd8900 6/9: lisp/ox-latex.el: Add the `:literal' attribute to verse block., ELPA Syncer, 2023/08/18
- [elpa] externals/org b3660cf135 7/9: * testing/lisp/test-org-attach-git.el: Avoid using global git config, ELPA Syncer, 2023/08/18
- [elpa] externals/org f1359546ad 5/9: org-element-at-point: Throw an error when not in org-mode, ELPA Syncer, 2023/08/18
- [elpa] externals/org 79aa149143 8/9: org-babel-map-executable: Describe header arg in the docstring, ELPA Syncer, 2023/08/18
- [elpa] externals/org 933d282881 3/9: Fix Emacs 27 false-positive warnings,
ELPA Syncer <=