[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/corfu 03558e1935: Bind completion-extra-properties in c
From: |
ELPA Syncer |
Subject: |
[elpa] externals/corfu 03558e1935: Bind completion-extra-properties in corfu--metadata-get |
Date: |
Tue, 9 Jul 2024 15:57:44 -0400 (EDT) |
branch: externals/corfu
commit 03558e1935156e2ca5181b5706ffb0177faa6148
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Daniel Mendler <mail@daniel-mendler.de>
Bind completion-extra-properties in corfu--metadata-get
---
corfu.el | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/corfu.el b/corfu.el
index 1a9f2cb529..edb1a7a6f2 100644
--- a/corfu.el
+++ b/corfu.el
@@ -714,7 +714,8 @@ FRAME is the existing frame."
(defun corfu--metadata-get (prop)
"Return PROP from completion metadata."
;; Marginalia are too heavy for the popup.
- (cl-letf (((symbol-function 'marginalia--completion-metadata-get) #'ignore))
+ (cl-letf (((symbol-function 'marginalia--completion-metadata-get) #'ignore)
+ (completion-extra-properties (nth 4 completion-in-region--data)))
(compat-call completion-metadata-get corfu--metadata prop)))
(defun corfu--format-candidates (cands)
@@ -1076,9 +1077,10 @@ A scroll bar is displayed from LO to LO+BAR."
(cl-defgeneric corfu--affixate (cands)
"Annotate CANDS with annotation function."
- (let* ((completion-extra-properties (nth 4 completion-in-region--data))
- (dep (plist-get completion-extra-properties :company-deprecated))
- (mf (run-hook-with-args-until-success 'corfu-margin-formatters
corfu--metadata)))
+ (let* ((extras (nth 4 completion-in-region--data))
+ (dep (plist-get extras :company-deprecated))
+ (mf (let ((completion-extra-properties extras))
+ (run-hook-with-args-until-success 'corfu-margin-formatters
corfu--metadata))))
(setq cands
(if-let ((aff (corfu--metadata-get 'affixation-function)))
(funcall aff cands)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [elpa] externals/corfu 03558e1935: Bind completion-extra-properties in corfu--metadata-get,
ELPA Syncer <=