[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#23387: 25.0.93; Unicode quote inserted in Python mode outside of str
From: |
Paul Eggert |
Subject: |
bug#23387: 25.0.93; Unicode quote inserted in Python mode outside of strings |
Date: |
Mon, 2 May 2016 09:04:18 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.0 |
Thanks for the bug report and patch, but I ran into a problem with the
patch. Suppose I do this:
emacs -Q
M-x electric-quote-mode
M-x customize-variable RET electric-quote-string, set it to t, save
M-x python-mode
'abc'
That is, I type apostrophe-a-b-c-apostrophe in Python mode. With the
patch, the buffer will contain:
'abc’
The opening apostrophe is OK, but the closing apostrophe is considered
to be inside a string so it is transmogrified into a right single
quotation mark. A Python programmer would want both to be apostrophes.
I installed the attached patches into emacs-25 instead, as they should
address this problem too. Please give it a try.
0001-Don-t-electrically-quote-in-Python.patch
Description: Source code patch
0002-Add-electric-quote-string-unit-test.patch
Description: Source code patch
- bug#23387: 25.0.93; Unicode quote inserted in Python mode outside of strings,
Paul Eggert <=