emacs: Replace 'guix-any' with 'cl-some'.
* emacs/guix-utils.el (guix-any): Remove. * emacs/guix-command.el (guix-command-improve-argument): Use 'cl-some' instead of 'guix-any'.
This commit is contained in:
parent
eda1cc8b5d
commit
b2cb869cf9
@ -305,9 +305,9 @@ to be modified."
|
||||
|
||||
(defun guix-command-improve-argument (argument improvers)
|
||||
"Return ARGUMENT modified with IMPROVERS."
|
||||
(or (guix-any (lambda (improver)
|
||||
(funcall improver argument))
|
||||
improvers)
|
||||
(or (cl-some (lambda (improver)
|
||||
(funcall improver argument))
|
||||
improvers)
|
||||
argument))
|
||||
|
||||
(defun guix-command-improve-arguments (arguments commands)
|
||||
|
@ -226,14 +226,6 @@ single argument."
|
||||
(while (re-search-forward ,regexp nil t)
|
||||
,@body)))
|
||||
|
||||
(defun guix-any (pred lst)
|
||||
"Test whether any element from LST satisfies PRED.
|
||||
If so, return the return value from the successful PRED call.
|
||||
Return nil otherwise."
|
||||
(when lst
|
||||
(or (funcall pred (car lst))
|
||||
(guix-any pred (cdr lst)))))
|
||||
|
||||
|
||||
;;; Alist accessors
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user