GNU bug report logs - #54682
29.0.50; [PATCH] Improve Eshell's logic for finding delimiters in arguments

Previous Next

Package: emacs;

Reported by: Jim Porter <jporterbugs <at> gmail.com>

Date: Sat, 2 Apr 2022 17:31:02 UTC

Severity: normal

Tags: patch

Found in version 29.0.50

Fixed in version 29.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 54682 in the body.
You can then email your comments to 54682 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#54682; Package emacs. (Sat, 02 Apr 2022 17:31:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Jim Porter <jporterbugs <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sat, 02 Apr 2022 17:31:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 29.0.50; [PATCH] Improve Eshell's logic for finding delimiters in
 arguments
Date: Sat, 2 Apr 2022 10:30:10 -0700
[Message part 1 (text/plain, inline)]
From "emacs -Q --eval '(eshell)'":

  ;; Good:
  ~ $ echo "\\foo"
  \foo

  ;; Bad:
  ~ $ echo "\\"
  Expecting completion of delimiter " ...

This is an issue with the logic for `eshell-find-delimiter'. When seeing 
the first '\', it didn't recognize that the second '\' was being 
escaped. Then, it looked at the second '\' and saw that it preceded a 
'"', thus thinking that the '"' was escaped and the string was 
unterminated. The fix is that `eshell-find-delimiter' should treat '\' 
as an escapable character when using backslash escapes.

In addition, I fixed the docstring. Previously, it said that backslash 
escaping only occurred when BACKSLASH-P was non-nil *and* the opening 
and closing delimiters are the same. However, when the opening and 
closing delimiters are different, backslash escaping is always used.
[0001-Fix-handling-of-inside-double-quotes-in-Eshell.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#54682; Package emacs. (Sun, 03 Apr 2022 12:18:02 GMT) Full text and rfc822 format available.

Message #8 received at 54682 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Jim Porter <jporterbugs <at> gmail.com>
Cc: 54682 <at> debbugs.gnu.org
Subject: Re: bug#54682: 29.0.50; [PATCH] Improve Eshell's logic for finding
 delimiters in arguments
Date: Sun, 03 Apr 2022 14:17:03 +0200
Jim Porter <jporterbugs <at> gmail.com> writes:

> In addition, I fixed the docstring. Previously, it said that backslash
> escaping only occurred when BACKSLASH-P was non-nil *and* the opening
> and closing delimiters are the same. However, when the opening and
> closing delimiters are different, backslash escaping is always used.

Thanks; pushed to Emacs 29.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




bug marked as fixed in version 29.1, send any further explanations to 54682 <at> debbugs.gnu.org and Jim Porter <jporterbugs <at> gmail.com> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Sun, 03 Apr 2022 12:18:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#54682; Package emacs. (Mon, 04 Apr 2022 04:15:02 GMT) Full text and rfc822 format available.

Message #13 received at 54682 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: 54682 <at> debbugs.gnu.org
Subject: Re: bug#54682: 29.0.50; [PATCH] Improve Eshell's logic for finding
 delimiters in arguments
Date: Sun, 3 Apr 2022 21:14:34 -0700
On 4/3/2022 5:17 AM, Lars Ingebrigtsen wrote:
> Thanks; pushed to Emacs 29.

Thanks for merging.

(Just a note for those who might be interested in this fix: there are 
still a few escaping-related bugs in Eshell that I'm working on fixes 
for. I'll try to post a patch for those after bug#54470 merges, since my 
patch builds on the patches in that bug.)




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 02 May 2022 11:24:07 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 107 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.