From c2ef3c2a231b55fd3427f37c8f922bae3f780372 Mon Sep 17 00:00:00 2001 From: Jim Porter Date: Sat, 11 Mar 2023 15:37:38 -0800 Subject: [PATCH 1/3] ; Remove unused Eshell target type Eshell creates all output targets in 'eshell-get-target', and that function never returns a cons cell. * lisp/eshell/esh-io.el (eshell-close-target) (eshell-output-object-to-target): Remove 'consp' condition. --- lisp/eshell/esh-io.el | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/lisp/eshell/esh-io.el b/lisp/eshell/esh-io.el index cccdb49ce2a..1ec4f918282 100644 --- a/lisp/eshell/esh-io.el +++ b/lisp/eshell/esh-io.el @@ -466,13 +466,7 @@ eshell-close-target ;; A plain function redirection needs no additional arguments ;; passed. ((functionp target) - (funcall target status)) - - ;; But a more complicated function redirection (which can only - ;; happen with aliases at the moment) has arguments that need to be - ;; passed along with it. - ((consp target) - (apply (car target) status (cdr target))))) + (funcall target status)))) (defun eshell-kill-append (string) "Call `kill-append' with STRING, if it is indeed a string." @@ -642,10 +636,7 @@ eshell-output-object-to-target (if (memq (process-status target) '(run stop open closed)) (signal (car err) (cdr err)) - (signal 'eshell-pipe-broken (list target)))))) - - ((consp target) - (apply (car target) object (cdr target)))) + (signal 'eshell-pipe-broken (list target))))))) object) (defun eshell-output-object (object &optional handle-index handles) -- 2.25.1