GNU bug report logs -
#29812
27.0.50; electric-quote-replace-double misbehaves in Lisp strings
Previous Next
Reported by: Eli Zaretskii <eliz <at> gnu.org>
Date: Fri, 22 Dec 2017 13:41:02 UTC
Severity: normal
Found in version 27.0.50
Done: Philipp Stephani <p.stephani2 <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Eli Zaretskii <eliz <at> gnu.org> schrieb am So., 31. Dez. 2017 um 18:00 Uhr:
> > From: Philipp Stephani <p.stephani2 <at> gmail.com>
> > Date: Sun, 31 Dec 2017 16:49:31 +0000
> > Cc: 29812 <at> debbugs.gnu.org
> >
> > In C, "\"foo\"" produces ASCII quotes.
> >
> > Did you enable electric-quote-string?
>
> Should I?
>
Yes, it's nil by default.
>
> > Well, can you give an example where it does work in strings? Maybe
> > I'm missing something, because it looked to me as if it never works in
> > that case.
> >
> > Depends on what you mean with "work".
>
> I mean some way of inserting “foo” inside a string. Is that possible
> somehow?
>
Sure, either by inserting the characters in some other way, or by using ``
and '' (double apostrophe).
>
> > A bare " should always close the string; after a \ it currently inserts
> > an opening quote because it only looks back one character.
>
> Which is a bug, isn't it?
>
Maybe. As said, it's a heuristic, and there's no unambiguous "correct"
behavior. But the patch I've sent modifies the behavior so that it ignores
the escape character.
[Message part 2 (text/html, inline)]
This bug report was last modified 7 years and 133 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.