From cc61045c3f04a81831298ef4cdec52e722d9fafe Mon Sep 17 00:00:00 2001 From: Feng Shu Date: Sun, 8 Dec 2019 13:25:58 +0800 Subject: [PATCH] Deal with "heading:[abc]+[def]+" style search regexp. Fix #64 * (org-ql--query-preamble): use (regexp ,regexp) to proper insert regexp string. --- org-ql.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/org-ql.el b/org-ql.el index 1f39d3f..40d7db5 100644 --- a/org-ql.el +++ b/org-ql.el @@ -685,14 +685,14 @@ replace the clause with a preamble." ;; Only one regexp: match with preamble, then let predicate confirm (because ;; the match could be in e.g. the tags rather than the heading text). (setq org-ql-preamble (rx-to-string `(seq bol (1+ "*") (1+ blank) (0+ nonl) - ,regexp) + (regexp ,regexp)) 'no-group)) element) (`(heading . ,regexps) ;; Multiple regexps: use preamble to match against first ;; regexp, then let the predicate match the rest. (setq org-ql-preamble (rx-to-string `(seq bol (1+ "*") (1+ blank) (0+ nonl) - ,(car regexps)) + (regexp ,(car regexps))) 'no-group)) element)