Fix: (org-ql--define-query-preamble-fn) Pcase pattern for Emacs 30
Now all tests and lints pass on Emacs versions 27.1-29.4, and the current 30.0.50-ish snapshot build. Note: This change was originally applied on master, but it seems reasonable to apply it to this stable bugfix release now. Fixes #433. Reported-by: Akira Komamura <akira.komamura@gmail.com> Co-developed-by: Stefan Monnier <monnier@iro.umontreal.ca>
This commit is contained in:
parent
5ea97d2272
commit
e241354fd6
3 changed files with 56 additions and 44 deletions
|
|
@ -1118,7 +1118,10 @@ defined in `org-ql-predicates' by calling `org-ql-defpred'."
|
|||
;; Only one preamble is allowed
|
||||
element)
|
||||
(pcase element
|
||||
(`(or _) element)
|
||||
(`(or ,element)
|
||||
;; A predicate with a single name: unwrap the OR. (Pcase doesn't like
|
||||
;; "one-armed ORs", giving a "Please avoid it" compilation error.)
|
||||
element)
|
||||
|
||||
,@preamble-patterns
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue