From fb85655fafc082f7d67898553cb841d74c7bc411 Mon Sep 17 00:00:00 2001 From: Daniel Mendler Date: Thu, 13 Apr 2023 09:15:03 +0200 Subject: Formatting --- cape.el | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/cape.el b/cape.el index f492414..0bed89d 100644 --- a/cape.el +++ b/cape.el @@ -824,20 +824,20 @@ completion table is refreshed on every input change." (pcase (funcall capf) (`(,beg ,end ,table . ,plist) `(,beg ,end - ,(let* ((beg (copy-marker beg)) - (end (copy-marker end t)) - (input (buffer-substring-no-properties beg end))) - (lambda (str pred action) - (let ((new-input (buffer-substring-no-properties beg end))) - (unless (or (string-match-p "\\s-" new-input) ;; Support Orderless - (funcall valid input new-input)) - (pcase (funcall capf) - (`(,_beg ,_end ,new-table . ,_plist) - ;; NOTE: We have to make sure that the completion table is interruptible. - ;; An interruption should not happen between the setqs. - (setq table new-table input new-input))))) - (complete-with-action action table str pred))) - ,@plist)))) + ,(let* ((beg (copy-marker beg)) + (end (copy-marker end t)) + (input (buffer-substring-no-properties beg end))) + (lambda (str pred action) + (let ((new-input (buffer-substring-no-properties beg end))) + (unless (or (string-match-p "\\s-" new-input) ;; Support Orderless + (funcall valid input new-input)) + (pcase (funcall capf) + (`(,_beg ,_end ,new-table . ,_plist) + ;; NOTE: We have to make sure that the completion table is interruptible. + ;; An interruption should not happen between the setqs. + (setq table new-table input new-input))))) + (complete-with-action action table str pred))) + ,@plist)))) ;;;###autoload (defun cape-wrap-properties (capf &rest properties) -- cgit v1.0