[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/consult 5e6749c: Simplify consult--regexp-compiler
From: |
ELPA Syncer |
Subject: |
[elpa] externals/consult 5e6749c: Simplify consult--regexp-compiler |
Date: |
Sat, 7 Aug 2021 13:57:06 -0400 (EDT) |
branch: externals/consult
commit 5e6749ce6ccc82efa4737cd51db0f3e41037d563
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Daniel Mendler <mail@daniel-mendler.de>
Simplify consult--regexp-compiler
---
consult.el | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/consult.el b/consult.el
index c7d5423..405470c 100644
--- a/consult.el
+++ b/consult.el
@@ -602,7 +602,7 @@ If no capturing groups are used highlight the whole match."
(lambda (x) (or (cdr (assoc x consult--convert-regexp-table)) x))
regexp 'fixedcase 'literal)))
-(defun consult--default-regexp-compiler (input type &rest _config)
+(defun consult--default-regexp-compiler (input type)
"Compile the INPUT string to a list of regular expressions.
The function should return a pair, the list of regular expressions and a
highlight function. The highlight function should take a single argument, the
@@ -4113,7 +4113,7 @@ INITIAL is inital input."
(pcase-let* ((cmd (split-string-and-unquote consult-grep-args))
(type (consult--grep-regexp-type (car cmd)))
(`(,arg . ,opts) (consult--command-split input))
- (`(,re . ,hl) (funcall consult--regexp-compiler arg type
:command 'consult-grep)))
+ (`(,re . ,hl) (funcall consult--regexp-compiler arg type)))
(when re
(list :command
(append cmd
@@ -4149,7 +4149,7 @@ Otherwise the `default-directory' is searched."
(defun consult--git-grep-builder (input)
"Build command line given CONFIG and INPUT."
(pcase-let* ((`(,arg . ,opts) (consult--command-split input))
- (`(,re . ,hl) (funcall consult--regexp-compiler arg 'extended
:command 'consult-git-grep)))
+ (`(,re . ,hl) (funcall consult--regexp-compiler arg 'extended)))
(when re
(list :command
(append (split-string-and-unquote consult-git-grep-args)
@@ -4179,7 +4179,7 @@ See `consult-grep' for more details."
(pcase-let* ((cmd (split-string-and-unquote consult-ripgrep-args))
(type (consult--ripgrep-regexp-type (car cmd)))
(`(,arg . ,opts) (consult--command-split input))
- (`(,re . ,hl) (funcall consult--regexp-compiler arg type
:command 'consult-ripgrep)))
+ (`(,re . ,hl) (funcall consult--regexp-compiler arg type)))
(when re
(list :command
(append cmd
@@ -4236,7 +4236,7 @@ INITIAL is inital input."
(pcase-let* ((cmd (split-string-and-unquote consult-find-args))
(type (consult--find-regexp-type (car cmd)))
(`(,arg . ,opts) (consult--command-split input))
- (`(,re . ,hl) (funcall consult--regexp-compiler arg type
:command 'consult-find)))
+ (`(,re . ,hl) (funcall consult--regexp-compiler arg type)))
(when re
(list :command
(append cmd
@@ -4268,7 +4268,7 @@ See `consult-grep' for more details regarding the
asynchronous search."
(defun consult--locate-builder (input)
"Build command line given INPUT."
(pcase-let* ((`(,arg . ,opts) (consult--command-split input))
- (`(,re . ,hl) (funcall consult--regexp-compiler arg 'basic
:command 'consult-locate)))
+ (`(,re . ,hl) (funcall consult--regexp-compiler arg 'basic)))
(when re
(list :command
(append (split-string-and-unquote consult-locate-args)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [elpa] externals/consult 5e6749c: Simplify consult--regexp-compiler,
ELPA Syncer <=