]> git.eshelyaron.com Git - emacs.git/commit
Simplify parsing subcommands slightly
authorJim Porter <jporterbugs@gmail.com>
Tue, 21 Mar 2023 00:25:24 +0000 (17:25 -0700)
committerJim Porter <jporterbugs@gmail.com>
Tue, 28 Mar 2023 19:02:46 +0000 (12:02 -0700)
commitbb088885df7a8e8a32670286a8636db8c6fadcf4
tree41c49343ed8d074f3dac970dfd24bcbe4e83f641
parent5b005f26a831881b0509f05d3b28dafbbe5bad41
Simplify parsing subcommands slightly

This mainly reduces some overly-deep indentation, but also fixes some
minor issues with the "$<subcmd>" form: it unnecessarily added " >
TEMP" (we already set this later via 'eshell-create-handles'), and it
didn't properly unescape inner double quotes.

* lisp/eshell/esh-cmd.el (eshell-parse-subcommand-argument): Simplify.

* lisp/eshell/esh-var.el (eshell-parse-variable-ref): Simplify and
fix edge cases in "$<subcmd>".

* test/lisp/eshell/esh-var-tests.el
(esh-var-test/quoted-interp-temp-cmd): Adjust test to check behavior
of inner double quotes.
lisp/eshell/esh-cmd.el
lisp/eshell/esh-var.el
test/lisp/eshell/esh-var-tests.el