[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/trie db78411 107/111: Switch to keyword arguments for t
From: |
Stefan Monnier |
Subject: |
[elpa] externals/trie db78411 107/111: Switch to keyword arguments for trie/dictree query functions. |
Date: |
Mon, 14 Dec 2020 11:35:30 -0500 (EST) |
branch: externals/trie
commit db784111f52194ae5499c4c4662cba7ec4e21e4d
Author: Toby S. Cubitt <toby-predictive@dr-qubit.org>
Commit: Toby S. Cubitt <toby-predictive@dr-qubit.org>
Switch to keyword arguments for trie/dictree query functions.
Allow pfxfilter in dict-tree queries.
---
trie.el | 47 +++++++++++++++++++++++------------------------
1 file changed, 23 insertions(+), 24 deletions(-)
diff --git a/trie.el b/trie.el
index 53f3ce6..6f5b5d5 100644
--- a/trie.el
+++ b/trie.el
@@ -1233,7 +1233,7 @@ is more efficient."
repopulatefun store pushed)
-(defun trie-stack (trie &optional type reverse pfxfilter)
+(defun* trie-stack (trie &key type reverse pfxfilter)
"Return an object that allows TRIE to be accessed as a stack.
The stack is sorted in \"lexicographic\" order, i.e. the order
@@ -1366,7 +1366,7 @@ element stored in the trie.)"
;; terms of trie-stacks.
(heap--when-generators
- (iter-defun trie-iter (trie &optional type reverse pfxfilter)
+ (cl-iter-defun trie-iter (trie &key type reverse pfxfilter)
"Return a trie iterator object.
Calling `iter-next' on this object will retrieve the next element
@@ -1585,8 +1585,8 @@ results\)."
;; ================================================================
;; Completing
-(defun trie-complete
- (trie prefix &optional rankfun maxnum reverse filter resultfun pfxfilter)
+(defun* trie-complete
+ (trie prefix &key rankfun maxnum reverse filter resultfun pfxfilter)
"Return an alist containing all completions of PREFIX in TRIE
along with their associated data, in the order defined by
RANKFUN, defaulting to \"lexicographic\" order \(i.e. the order
@@ -1665,7 +1665,7 @@ is more efficient than using FILTER for the same purpose."
-(defun trie-complete-stack (trie prefix &optional reverse pfxfilter)
+(defun* trie-complete-stack (trie prefix &key reverse pfxfilter)
"Return an object that allows completions of PREFIX to be accessed
as if they were a stack.
@@ -1737,7 +1737,7 @@ instead."
(heap--when-generators
- (iter-defun trie-complete-iter (trie prefix &optional reverse pfxfilter)
+ (cl-iter-defun trie-complete-iter (trie prefix &key reverse pfxfilter)
"Return an iterator object for completions of PREFIX in TRIE.
Calling `iter-next' on this object will retrieve the next
@@ -1774,8 +1774,8 @@ results\)."
;; ================================================================
;; Regexp search
-(defun trie-regexp-search
- (trie regexp &optional rankfun maxnum reverse filter resultfun pfxfilter)
+(defun* trie-regexp-search
+ (trie regexp &key maxnum reverse rankfun filter pfxfilter resultfun)
"Return an alist containing all matches for REGEXP in TRIE
along with their associated data, in the order defined by
RANKFUN, defaulting to \"lexicographic\" order \(i.e. the order
@@ -1959,7 +1959,7 @@ is more efficient than using FILTER for the same purpose."
(trie--node-data node))))))
-(defun trie-regexp-stack (trie regexp &optional reverse pfxfilter)
+(defun* trie-regexp-stack (trie regexp &key reverse pfxfilter)
"Return an object that allows matches to REGEXP to be accessed
as if they were a stack.
@@ -2121,7 +2121,7 @@ as a prefix are omitted from the stack."
(heap--when-generators
- (iter-defun trie-regexp-iter (trie regexp &optional reverse pfxfilter)
+ (cl-iter-defun trie-regexp-iter (trie regexp &key reverse pfxfilter)
"Return an iterator object for REGEXP matches in TRIE.
Calling `iter-next' on this object will retrieve the next match
@@ -2282,9 +2282,9 @@ See also `Lewenstein-distance'."
;; (similarly to regexp searches, cf. `trie-regexp-match'.)
-(defun trie-fuzzy-match
- (trie string distance &optional rankfun maxnum reverse
- filter resultfun pfxfilter)
+(defun* trie-fuzzy-match
+ (trie string distance
+ &key maxnum reverse rankfun filter pfxfilter resultfun)
"Return matches for STRING in TRIE within Lewenstein DISTANCE
\(edit distance\) of STRING along with their associated data, in
the order defined by RANKFUN, defaulting to \"lexicographic\"
@@ -2446,8 +2446,7 @@ efficient than using FILTER for the same purpose."
-(defun trie-fuzzy-match-stack (trie string distance
- &optional reverse pfxfilter)
+(defun* trie-fuzzy-match-stack (trie string distance &key reverse pfxfilter)
"Return an object that allows fuzzy matches to be accessed
as if they were a stack.
@@ -2584,8 +2583,8 @@ a prefix are omitted from the stack."
(heap--when-generators
- (iter-defun trie-fuzzy-match-iter (trie string distance
- &optional reverse pfxfilter)
+ (cl-iter-defun trie-fuzzy-match-iter (trie string distance
+ &key reverse pfxfilter)
"Return an iterator object for fuzzy matches to STRING in TRIE.
Calling `iter-next' on this object will return the next match
@@ -2631,9 +2630,9 @@ results\)."
;; ================================================================
;; Fuzzy completing
-(defun trie-fuzzy-complete
- (trie prefix distance &optional rankfun maxnum reverse
- filter resultfun pfxfilter)
+(defun* trie-fuzzy-complete
+ (trie prefix distance
+ &key maxnum reverse rankfun filter pfxfilter resultfun)
"Return completions of prefixes within Lewenstein DISTANCE of PREFIX
along with their associated data, in the order defined by
RANKFUN, defaulting to \"lexicographic\" order \(i.e. the order
@@ -2853,8 +2852,8 @@ is more efficient than using FILTER for the same purpose."
-(defun trie-fuzzy-complete-stack (trie prefix distance
- &optional reverse pfxfilter)
+(defun* trie-fuzzy-complete-stack
+ (trie prefix distance &key reverse pfxfilter)
"Return an object that allows fuzzy completions to be accessed
as if they were a stack.
@@ -3024,8 +3023,8 @@ as a prefix are omitted from the stack."
(heap--when-generators
- (iter-defun trie-fuzzy-complete-iter (trie prefix distance
- &optional reverse pfxfilter)
+ (cl-iter-defun trie-fuzzy-complete-iter (trie prefix distance
+ &key reverse pfxfilter)
"Return an iterator object for fuzzy matches of STRING in TRIE.
Calling `iter-next' on this object will return the next match
- [elpa] externals/trie 4efa42d 067/111: Fix trie--node-data defsetf, so it compiles in latest Emacs trunk., (continued)
- [elpa] externals/trie 4efa42d 067/111: Fix trie--node-data defsetf, so it compiles in latest Emacs trunk., Stefan Monnier, 2020/12/14
- [elpa] externals/trie 9986ac7 068/111: Restore trie print/read transformer functions., Stefan Monnier, 2020/12/14
- [elpa] externals/trie ec5396c 071/111: Suppress bogus unused lexical variable byte-compiler warnings., Stefan Monnier, 2020/12/14
- [elpa] externals/trie acad8e8 050/111: Bug-fixes to edebug advice, Stefan Monnier, 2020/12/14
- [elpa] externals/trie 15b4de9 018/111: Simplified trie--create by storing functions for predefined trie types in symbol property lists, Stefan Monnier, 2020/12/14
- [elpa] externals/trie fb1d096 034/111: Changed trie-wildcard-match to return grouping data if pattern matches and contains groups, Stefan Monnier, 2020/12/14
- [elpa] externals/trie 4ff2b48 057/111: Minor typo-fixes in docstrings., Stefan Monnier, 2020/12/14
- [elpa] externals/trie a8bc50f 041/111: Minor code tidying, Stefan Monnier, 2020/12/14
- [elpa] externals/trie 0d81a80 066/111: Remove dependency on Emacs version, since this is currently broken in ELPA., Stefan Monnier, 2020/12/14
- [elpa] externals/trie 673ca83 013/111: Don't compile wrapped functions explicitly, Stefan Monnier, 2020/12/14
- [elpa] externals/trie db78411 107/111: Switch to keyword arguments for trie/dictree query functions.,
Stefan Monnier <=
- [elpa] externals/trie f676ea0 091/111: Fix off-by-1 bug in Lewenstein distance queries., Stefan Monnier, 2020/12/14
- [elpa] externals/trie eef13c4 079/111: Document fuzzy matching functions and bump version number., Stefan Monnier, 2020/12/14
- [elpa] externals/trie 77aafc9 108/111: Fix byte-compilation errors and warnings., Stefan Monnier, 2020/12/14
- [elpa] externals/trie b6ba36b 002/111: Minor improvements to trie-complete[-ordered], Stefan Monnier, 2020/12/14
- [elpa] externals/trie 503b286 004/111: Make bare avl trees which don't store cmpfun with tree, Stefan Monnier, 2020/12/14
- [elpa] externals/trie 0162b74 003/111: Added trie-stacks implementation., Stefan Monnier, 2020/12/14
- [elpa] externals/trie 45569c2 007/111: Added optional TEST function to trie-delete, Stefan Monnier, 2020/12/14
- [elpa] externals/trie 45accae 019/111: Bug-fix in trie--do-delete, Stefan Monnier, 2020/12/14
- [elpa] externals/trie 4f11b37 022/111: Docstring, change log, and version number updates, Stefan Monnier, 2020/12/14
- [elpa] externals/trie 510844e 035/111: trivial variable name change, Stefan Monnier, 2020/12/14