From b0427f5ffe17c5a2a2aa0d993b164739c16193c0 Mon Sep 17 00:00:00 2001 From: Jim Porter Date: Sat, 2 Sep 2023 16:07:59 -0700 Subject: [PATCH] ; Add debug instrumentation for Eshell argument modifiers * lisp/eshell/esh-arg.el (eshell-resolve-current-argument): Add debug instrumentation, and simplify modifier application. --- lisp/eshell/esh-arg.el | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lisp/eshell/esh-arg.el b/lisp/eshell/esh-arg.el index 26be1127880..e9c6a7f2f68 100644 --- a/lisp/eshell/esh-arg.el +++ b/lisp/eshell/esh-arg.el @@ -293,10 +293,13 @@ then the result will be: (append (list 'eshell-concat eshell-current-quoted) eshell-current-argument))) (setq eshell-arg-listified nil)) - (while eshell-current-modifiers + (when eshell-current-modifiers + (eshell-debug-command 'form (format-message "applying modifiers %S" + eshell-current-modifiers) + eshell-current-argument)) + (dolist (modifier eshell-current-modifiers) (setq eshell-current-argument - (list (car eshell-current-modifiers) eshell-current-argument) - eshell-current-modifiers (cdr eshell-current-modifiers)))) + (list modifier eshell-current-argument)))) (setq eshell-current-modifiers nil)) (defun eshell-finish-arg (&rest arguments) -- 2.39.2