This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: regex nit in encoding declarations
Type: Stage:
Components: Documentation Versions: Python 2.3
process
Status: closed Resolution: accepted
Dependencies: Superseder:
Assigned To: Nosy List: loewis, quiver
Priority: normal Keywords: patch

Created on 2004-08-18 02:04 by quiver, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
ref2.tex.diff quiver, 2004-08-18 02:04 Python Reference Manual
0263.diff quiver, 2004-08-18 02:06 PEP 0263
Messages (2)
msg46729 - (view) Author: George Yoshida (quiver) (Python committer) Date: 2004-08-18 02:04
This patch is related to bug #995522.

Reference Manual recommends that encoding 
declarations match the pattern
  "coding[=:]\s*([\w-_.]+)"
But this pattern has two problems.

1. - mark needs to be escaped or placed as the first 
character.
   (bug #995522)
2. \w is same as [a-zA-Z0-9_], so there's no need to 
include _ in [].

Then the pattern will become
  coding[=:]\s*([-\w.]+)

The patch is for PEP-0263 and Python Reference Manual.

Thanks.
msg46730 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2004-08-18 13:26
Logged In: YES 
user_id=21627

Thanks for the patch. Committed as ref2.tex 1.54 and
pep-0263.txt 1.54.
History
Date User Action Args
2022-04-11 14:56:06adminsetgithub: 40777
2004-08-18 02:04:10quivercreate