[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/transient 5e841bb24b 19/41: transient-infix-set(argumen
From: |
Jonas Bernoulli |
Subject: |
[elpa] externals/transient 5e841bb24b 19/41: transient-infix-set(argument): Replace :around with :after method |
Date: |
Sun, 12 Nov 2023 20:04:08 -0500 (EST) |
branch: externals/transient
commit 5e841bb24ba5a0b5f169b432349871dd04721a39
Author: Jonas Bernoulli <jonas@bernoul.li>
Commit: Jonas Bernoulli <jonas@bernoul.li>
transient-infix-set(argument): Replace :around with :after method
---
lisp/transient.el | 33 +++++++++++++++------------------
1 file changed, 15 insertions(+), 18 deletions(-)
diff --git a/lisp/transient.el b/lisp/transient.el
index 5087a7f770..599d6c7c0c 100644
--- a/lisp/transient.el
+++ b/lisp/transient.el
@@ -3185,28 +3185,25 @@ prompt."
"Set the value of infix object OBJ to value."
(oset obj value value))
-(cl-defmethod transient-infix-set :around ((obj transient-argument) value)
+(cl-defmethod transient-infix-set :after ((obj transient-argument) value)
"Unset incompatible infix arguments."
(let ((arg (if (slot-boundp obj 'argument)
(oref obj argument)
(oref obj argument-regexp))))
- (if-let ((sic (and value arg))
- (spec (oref transient--prefix incompatible))
- (incomp (cl-mapcan (lambda (rule)
- (and (member arg rule)
- (remove arg rule)))
- spec)))
- (progn
- (cl-call-next-method obj value)
- (dolist (arg incomp)
- (when-let ((obj (cl-find-if
- (lambda (obj)
- (and (slot-exists-p obj 'argument)
- (slot-boundp obj 'argument)
- (equal (oref obj argument) arg)))
- transient--suffixes)))
- (transient-infix-set obj nil))))
- (cl-call-next-method obj value))))
+ (when-let ((sic (and value arg))
+ (spec (oref transient--prefix incompatible))
+ (incomp (cl-mapcan (lambda (rule)
+ (and (member arg rule)
+ (remove arg rule)))
+ spec)))
+ (dolist (arg incomp)
+ (when-let ((obj (cl-find-if
+ (lambda (obj)
+ (and (slot-exists-p obj 'argument)
+ (slot-boundp obj 'argument)
+ (equal (oref obj argument) arg)))
+ transient--suffixes)))
+ (transient-infix-set obj nil))))))
(cl-defgeneric transient-set-value (obj)
"Set the value of the transient prefix OBJ.")
- [elpa] externals/transient updated (a8829875b2 -> 3cd1de1695), Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient f769486803 02/41: Tweak some docstrings, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 59d602a2e8 05/41: transient--refreshp: New variable, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 92572454b5 06/41: transient-toggle-level-limit: New command, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 8098d17518 13/41: transient--make-predicate-map: Fix handling of transient-suffix, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 10d590dc55 07/41: transient-echo-arguments: Also echo command keys, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient f43aee1a5e 08/41: transient--suffix-prototype: New function, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 9a7eb0d9a3 09/41: transient--make-predicate-map: Use define-key exclusively, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 67671e1ac0 12/41: transient--make-predicate-map: Rearrange pcase cases, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 5e841bb24b 19/41: transient-infix-set(argument): Replace :around with :after method,
Jonas Bernoulli <=
- [elpa] externals/transient c6e3891537 21/41: transient-infix-set(argument): Cosmetics, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 425003a44b 22/41: transient-infix-set(argument): Limit to other arguments, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 8d8df0f038 20/41: transient-infix-set(argument): Cosmetics, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 9d9e931996 25/41: transient--shadowed-buffer: Renamed from transient--current-buffer, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 8e15a29b59 31/41: transient-format-description: Support function as value of face slot, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 533578b6b2 32/41: transient-information: Use a space as the fake key, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient 59d8c0342a 18/41: transient--unset-incompatible: Remove unnecessary variable, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient ed5bd6fdc3 23/41: transient-infix-set(argument): Fix disabling incompatible options, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient bad91f79ec 29/41: transient-with-shadowed-buffer: Move definition, Jonas Bernoulli, 2023/11/12
- [elpa] externals/transient cf32cf6f98 39/41: transient--get-face: Favor face over function, Jonas Bernoulli, 2023/11/12