Issue 14958: IDLE 3 and PEP414 - highlighting unicode literals
Created on 2012-05-30 00:37 by roger.serwy, last changed 2022-04-11 14:57 by admin. This issue is now closed.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| issue14958_27.patch | roger.serwy, 2012-06-01 03:22 | review | ||
| Messages (7) | |||
|---|---|---|---|
| msg161921 - (view) | Author: Roger Serwy (roger.serwy) * ![]() |
Date: 2012-05-30 00:37 | |
Issue8641 addressed the problem of not highlighting byte literals, but dropped Unicode literals, as it should have. This happened months before the acceptance of PEP414. IDLE 3 should now highlight u"" as well as b"", as well as valid combinations with r"". |
|||
| msg161927 - (view) | Author: Roundup Robot (python-dev) ![]() |
Date: 2012-05-30 05:56 | |
New changeset 94a5bf416e50 by Ned Deily in branch 'default': Issue #14958: Change IDLE systax highlighting to recognize all string and http://hg.python.org/cpython/rev/94a5bf416e50 |
|||
| msg161928 - (view) | Author: Ned Deily (ned.deily) * ![]() |
Date: 2012-05-30 06:04 | |
It turns out that the previous and current versions of IDLE syntax highlighting did not recognize literals with valid two-character prefixes, like "ur" or "br". Besides restoring "ur", 3.3 also added "rb" to the existing "br" prefixes. The applied patch explicitly matches any of the prefixes documented in the 3.3 language reference: http://docs.python.org/dev/reference/lexical_analysis.html#string-and-bytes-literals |
|||
| msg161929 - (view) | Author: Roger Serwy (roger.serwy) * ![]() |
Date: 2012-05-30 06:19 | |
Should the patch be partially back-ported to 2.7 as well given that IDLE 2 doesn't highlight two-character prefixes? |
|||
| msg161930 - (view) | Author: Ned Deily (ned.deily) * ![]() |
Date: 2012-05-30 06:25 | |
It could be. But perhaps its absence will be another incentive to move to Python 3.3. |
|||
| msg162046 - (view) | Author: Roger Serwy (roger.serwy) * ![]() |
Date: 2012-06-01 03:22 | |
Attached is a backport to 2.7. |
|||
| msg178718 - (view) | Author: Roundup Robot (python-dev) ![]() |
Date: 2012-12-31 23:07 | |
New changeset 0dbdb85fd141 by Ned Deily in branch '2.7': Issue #14958: backport to 2.7.x from 3.3 (patch by Roger Serwy) http://hg.python.org/cpython/rev/0dbdb85fd141 |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:57:31 | admin | set | github: 59163 |
| 2012-12-31 23:07:55 | python-dev | set | messages: + msg178718 |
| 2012-06-01 03:22:47 | roger.serwy | set | files:
+ issue14958_27.patch keywords: + patch messages: + msg162046 versions: + Python 2.7 |
| 2012-05-30 06:25:52 | ned.deily | set | messages: + msg161930 |
| 2012-05-30 06:19:31 | roger.serwy | set | messages: + msg161929 |
| 2012-05-30 06:05:52 | ned.deily | set | versions: - Python 3.2 |
| 2012-05-30 06:04:39 | ned.deily | set | status: open -> closed nosy:
+ ned.deily resolution: fixed |
| 2012-05-30 05:56:53 | python-dev | set | nosy:
+ python-dev messages: + msg161927 |
| 2012-05-30 00:37:48 | roger.serwy | create | |

