<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/cpython-git.git/Objects/stringlib/localeutil.h, branch fix-namedexpr-comment</title>
<subtitle>github.com: python/cpython.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/'/>
<entry>
<title>bpo-33954: Fix _PyUnicode_InsertThousandsGrouping() (GH-10623)</title>
<updated>2018-11-26T12:40:01+00:00</updated>
<author>
<name>Victor Stinner</name>
<email>vstinner@redhat.com</email>
</author>
<published>2018-11-26T12:40:01+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=59423e3ddd736387cef8f7632c71954c1859bed0'/>
<id>59423e3ddd736387cef8f7632c71954c1859bed0</id>
<content type='text'>
Fix str.format(), float.__format__() and complex.__format__() methods
for non-ASCII decimal point when using the "n" formatter.

Changes:

* Rewrite _PyUnicode_InsertThousandsGrouping(): it now requires
  a _PyUnicodeWriter object for the buffer and a Python str object
  for digits.
* Rename FILL() macro to unicode_fill(), convert it to static inline function,
  add "assert(0 &lt;= start);" and rework its code.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix str.format(), float.__format__() and complex.__format__() methods
for non-ASCII decimal point when using the "n" formatter.

Changes:

* Rewrite _PyUnicode_InsertThousandsGrouping(): it now requires
  a _PyUnicodeWriter object for the buffer and a Python str object
  for digits.
* Rename FILL() macro to unicode_fill(), convert it to static inline function,
  add "assert(0 &lt;= start);" and rework its code.</pre>
</div>
</content>
</entry>
<entry>
<title>Issue #26765: Ensure that bytes- and unicode-specific stringlib files are used</title>
<updated>2016-05-16T06:42:29+00:00</updated>
<author>
<name>Serhiy Storchaka</name>
<email>storchaka@gmail.com</email>
</author>
<published>2016-05-16T06:42:29+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=bcde10aa7e47da68afb68fe75c65b9339dd89f86'/>
<id>bcde10aa7e47da68afb68fe75c65b9339dd89f86</id>
<content type='text'>
with correct type.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
with correct type.
</pre>
</div>
</content>
</entry>
<entry>
<title>Make private function static (from `make smelly`)</title>
<updated>2012-06-21T15:26:28+00:00</updated>
<author>
<name>Antoine Pitrou</name>
<email>solipsis@pitrou.net</email>
</author>
<published>2012-06-21T15:26:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=a759d4e9f40fd0b757600d5fd3666cdddee113fe'/>
<id>a759d4e9f40fd0b757600d5fd3666cdddee113fe</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Issue #13706: Fix format(int, "n") for locale with non-ASCII thousands separator</title>
<updated>2012-02-23T23:37:51+00:00</updated>
<author>
<name>Victor Stinner</name>
<email>victor.stinner@haypocalc.com</email>
</author>
<published>2012-02-23T23:37:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=41a863cb81608c779d60b49e7be8a115816734fc'/>
<id>41a863cb81608c779d60b49e7be8a115816734fc</id>
<content type='text'>
 * Decode thousands separator and decimal point using PyUnicode_DecodeLocale()
   (from the locale encoding), instead of decoding them implicitly from latin1
 * Remove _PyUnicode_InsertThousandsGroupingLocale(), it was not used
 * Change _PyUnicode_InsertThousandsGrouping() API to return the maximum
   character if unicode is NULL
 * Replace MIN/MAX macros by Py_MIN/Py_MAX
 * stringlib/undef.h undefines STRINGLIB_IS_UNICODE
 * stringlib/localeutil.h only supports Unicode
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
 * Decode thousands separator and decimal point using PyUnicode_DecodeLocale()
   (from the locale encoding), instead of decoding them implicitly from latin1
 * Remove _PyUnicode_InsertThousandsGroupingLocale(), it was not used
 * Change _PyUnicode_InsertThousandsGrouping() API to return the maximum
   character if unicode is NULL
 * Replace MIN/MAX macros by Py_MIN/Py_MAX
 * stringlib/undef.h undefines STRINGLIB_IS_UNICODE
 * stringlib/localeutil.h only supports Unicode
</pre>
</div>
</content>
</entry>
<entry>
<title>Implement PEP 393.</title>
<updated>2011-09-28T05:41:54+00:00</updated>
<author>
<name>Martin v. Löwis</name>
<email>martin@v.loewis.de</email>
</author>
<published>2011-09-28T05:41:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=d63a3b8beb4a0841cb59fb3515347ccaab34b733'/>
<id>d63a3b8beb4a0841cb59fb3515347ccaab34b733</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>The other half of Issue #1580: use short float repr where possible.</title>
<updated>2009-04-16T20:16:10+00:00</updated>
<author>
<name>Eric Smith</name>
<email>eric@trueblade.com</email>
</author>
<published>2009-04-16T20:16:10+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=0923d1d8d7e428297461ed5145f06915c462b25b'/>
<id>0923d1d8d7e428297461ed5145f06915c462b25b</id>
<content type='text'>
Addresses the float -&gt; string conversion, using David Gay's code which
was added in Mark Dickinson's checkin r71663.

Also addresses these, which are intertwined with the short repr
changes:

- Issue #5772: format(1e100, '&lt;') produces '1e+100', not '1.0e+100'
- Issue #5515: 'n' formatting with commas no longer works poorly
    with leading zeros.
- PEP 378 Format Specifier for Thousands Separator: implemented
    for floats.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Addresses the float -&gt; string conversion, using David Gay's code which
was added in Mark Dickinson's checkin r71663.

Also addresses these, which are intertwined with the short repr
changes:

- Issue #5772: format(1e100, '&lt;') produces '1e+100', not '1.0e+100'
- Issue #5515: 'n' formatting with commas no longer works poorly
    with leading zeros.
- PEP 378 Format Specifier for Thousands Separator: implemented
    for floats.
</pre>
</div>
</content>
</entry>
<entry>
<title>Added ',' thousands grouping to int.__format__. See PEP 378.</title>
<updated>2009-04-03T14:45:06+00:00</updated>
<author>
<name>Eric Smith</name>
<email>eric@trueblade.com</email>
</author>
<published>2009-04-03T14:45:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=a3b1ac8dca5afa01d9d542e125052014a9af56eb'/>
<id>a3b1ac8dca5afa01d9d542e125052014a9af56eb</id>
<content type='text'>
This is incomplete, but I want to get some version into the next alpha. I am still working on:
Documentation.
More tests.
Implement for floats.

In addition, there's an existing bug with 'n' formatting that carries forward to thousands grouping (issue 5515).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is incomplete, but I want to get some version into the next alpha. I am still working on:
Documentation.
More tests.
Implement for floats.

In addition, there's an existing bug with 'n' formatting that carries forward to thousands grouping (issue 5515).
</pre>
</div>
</content>
</entry>
<entry>
<title>Merged revisions 64491 via svnmerge from</title>
<updated>2008-06-24T01:06:47+00:00</updated>
<author>
<name>Eric Smith</name>
<email>eric@trueblade.com</email>
</author>
<published>2008-06-24T01:06:47+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=6d7e7a730e05dbf3511f94df400984dd5b7bdfdc'/>
<id>6d7e7a730e05dbf3511f94df400984dd5b7bdfdc</id>
<content type='text'>
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r64491 | eric.smith | 2008-06-23 20:42:10 -0400 (Mon, 23 Jun 2008) | 1 line

  Modified interface to _Py_[String|Unicode]InsertThousandsGrouping, in anticipation of fixing issue 3140.
........
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r64491 | eric.smith | 2008-06-23 20:42:10 -0400 (Mon, 23 Jun 2008) | 1 line

  Modified interface to _Py_[String|Unicode]InsertThousandsGrouping, in anticipation of fixing issue 3140.
........
</pre>
</div>
</content>
</entry>
<entry>
<title>Merged revisions 63078 via svnmerge from</title>
<updated>2008-05-11T21:00:57+00:00</updated>
<author>
<name>Eric Smith</name>
<email>eric@trueblade.com</email>
</author>
<published>2008-05-11T21:00:57+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=5807c415c5b16b9119895cdc80c4608f37c8c30b'/>
<id>5807c415c5b16b9119895cdc80c4608f37c8c30b</id>
<content type='text'>
svn+ssh://pythondev@svn.python.org/python/trunk

When forward porting this, I added _PyUnicode_InsertThousandsGrouping.

........
  r63078 | eric.smith | 2008-05-11 15:52:48 -0400 (Sun, 11 May 2008) | 14 lines

  Addresses issue 2802: 'n' formatting for integers.

  Adds 'n' as a format specifier for integers, to mirror the same
  specifier which is already available for floats.  'n' is the same as
  'd', but inserts the current locale-specific thousands grouping.

  I added this as a stringlib function, but it's only used by str type,
  not unicode.  This is because of an implementation detail in
  unicode.format(), which does its own str-&gt;unicode conversion.  But the
  unicode version will be needed in 3.0, and it may be needed by other
  code eventually in 2.6 (maybe decimal?), so I left it as a stringlib
  implementation.  As long as the unicode version isn't instantiated,
  there's no overhead for this.
........
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
svn+ssh://pythondev@svn.python.org/python/trunk

When forward porting this, I added _PyUnicode_InsertThousandsGrouping.

........
  r63078 | eric.smith | 2008-05-11 15:52:48 -0400 (Sun, 11 May 2008) | 14 lines

  Addresses issue 2802: 'n' formatting for integers.

  Adds 'n' as a format specifier for integers, to mirror the same
  specifier which is already available for floats.  'n' is the same as
  'd', but inserts the current locale-specific thousands grouping.

  I added this as a stringlib function, but it's only used by str type,
  not unicode.  This is because of an implementation detail in
  unicode.format(), which does its own str-&gt;unicode conversion.  But the
  unicode version will be needed in 3.0, and it may be needed by other
  code eventually in 2.6 (maybe decimal?), so I left it as a stringlib
  implementation.  As long as the unicode version isn't instantiated,
  there's no overhead for this.
........
</pre>
</div>
</content>
</entry>
</feed>
