[issue27915] Use 'ascii' instead of 'us-ascii' to bypass lookup machinery

2016-09-05 Thread STINNER Victor

STINNER Victor added the comment:

Since "us-ascii" got a fast-path thanks to the issue #27938, this patch is not 
needed anymore.

--
resolution:  -> out of date
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27915] Use 'ascii' instead of 'us-ascii' to bypass lookup machinery

2016-09-02 Thread STINNER Victor

STINNER Victor added the comment:

It looks like the email module has a special usage of the "us-ascii" encoding 
name. It's not just an alias to "ascii". So I proposed a patch implementing the 
fast-path differently in the Python builtin codecs: see my issue #27938.

The xml.etree module has special cases for the "us-ascii" encoding name, but 
not for "ascii". See the ElementTree.write() method. I proposed to also skip 
the XML declaration by default when "ascii" encoding is used: issue #27940.

--
nosy: +haypo

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27915] Use 'ascii' instead of 'us-ascii' to bypass lookup machinery

2016-08-31 Thread Ville Skyttä

New submission from Ville Skyttä:

https://docs.python.org/3/library/codecs.html#standard-encodings

There are a bunch of other us-ascii occurrences in the tree; this patch covers 
the ones that are not user visible in a way that could cause problems or 
changes in behavior.

--
files: ascii.patch
keywords: patch
messages: 274028
nosy: scop
priority: normal
severity: normal
status: open
title: Use 'ascii' instead of 'us-ascii' to bypass lookup machinery
type: performance
Added file: http://bugs.python.org/file44300/ascii.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com