emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/orderless b63019aea3 090/204: Add missing (oops!) "forg


From: ELPA Syncer
Subject: [elpa] externals/orderless b63019aea3 090/204: Add missing (oops!) "forgiving funcall" function
Date: Tue, 11 Jan 2022 12:58:20 -0500 (EST)

branch: externals/orderless
commit b63019aea34f266f7bfbf244b23005993a5d7305
Author: Omar Antolín <omar.antolin@gmail.com>
Commit: Omar Antolín <omar.antolin@gmail.com>

    Add missing (oops!) "forgiving funcall" function
---
 orderless.el | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/orderless.el b/orderless.el
index ead96ea972..82fbcd8d65 100644
--- a/orderless.el
+++ b/orderless.el
@@ -292,6 +292,10 @@ converted to a list of regexps according to the value of
              for string = (copy-sequence original)
              collect (orderless--highlight regexps string)))
 
+(defun orderless--forgiving-funcall (fn &rest args)
+  "Call FN with as many ARGS as its arity allows."
+  (apply fn (cl-subseq args 0 (cdr (func-arity fn)))))
+
 (defun orderless--component-regexps (pattern)
   "Build regexps to match PATTERN.
 Consults `orderless-style-dispatchers' and, if



reply via email to

[Prev in Thread] Current Thread [Next in Thread]