<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/cpython-git.git/Python/mystrtoul.c, branch zooba-patch-1</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>Untabify C files. Will watch buildbots.</title>
<updated>2010-05-09T14:46:46+00:00</updated>
<author>
<name>Antoine Pitrou</name>
<email>solipsis@pitrou.net</email>
</author>
<published>2010-05-09T14:46:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=c83ea137d7e717f764e2f31fc2544f522de7d857'/>
<id>c83ea137d7e717f764e2f31fc2544f522de7d857</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert r61969 which added casts to Py_CHARMASK to avoid compiler warnings.</title>
<updated>2008-03-28T04:58:51+00:00</updated>
<author>
<name>Neal Norwitz</name>
<email>nnorwitz@gmail.com</email>
</author>
<published>2008-03-28T04:58:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=d183bdd6fb77ae562714c655f0689beacdc00da1'/>
<id>d183bdd6fb77ae562714c655f0689beacdc00da1</id>
<content type='text'>
Rather than sprinkle casts throughout the code, change Py_CHARMASK to
always cast it's result to an unsigned char.  This should ensure we
do the right thing when accessing an array with the result.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Rather than sprinkle casts throughout the code, change Py_CHARMASK to
always cast it's result to an unsigned char.  This should ensure we
do the right thing when accessing an array with the result.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix warnings about using char as an array subscript.  This is not portable</title>
<updated>2008-03-27T04:40:50+00:00</updated>
<author>
<name>Neal Norwitz</name>
<email>nnorwitz@gmail.com</email>
</author>
<published>2008-03-27T04:40:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=231346e23f3bcb5102199712b998ca7f2354dfdd'/>
<id>231346e23f3bcb5102199712b998ca7f2354dfdd</id>
<content type='text'>
since char is signed on some platforms and unsigned on others.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
since char is signed on some platforms and unsigned on others.
</pre>
</div>
</content>
</entry>
<entry>
<title>Finished backporting PEP 3127, Integer Literal Support and Syntax.</title>
<updated>2008-03-17T17:32:20+00:00</updated>
<author>
<name>Eric Smith</name>
<email>eric@trueblade.com</email>
</author>
<published>2008-03-17T17:32:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=9ff19b54346d39d15cdcf75e9d66ab46ea6064d6'/>
<id>9ff19b54346d39d15cdcf75e9d66ab46ea6064d6</id>
<content type='text'>
Added 0b and 0o literals to tokenizer.
Modified PyOS_strtoul to support 0b and 0o inputs.
Modified PyLong_FromString to support guessing 0b and 0o inputs.
Renamed test_hexoct.py to test_int_literal.py and added binary tests.
Added upper and lower case 0b, 0O, and 0X tests to test_int_literal.py
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Added 0b and 0o literals to tokenizer.
Modified PyOS_strtoul to support 0b and 0o inputs.
Modified PyLong_FromString to support guessing 0b and 0o inputs.
Renamed test_hexoct.py to test_int_literal.py and added binary tests.
Added upper and lower case 0b, 0O, and 0X tests to test_int_literal.py
</pre>
</div>
</content>
</entry>
<entry>
<title>Removed duplicate Py_CHARMASK define.  It's already defined in Python.h.</title>
<updated>2008-02-23T16:05:26+00:00</updated>
<author>
<name>Eric Smith</name>
<email>eric@trueblade.com</email>
</author>
<published>2008-02-23T16:05:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=8328bbc57dccbcbd834f822c2c9c70bd2ad199eb'/>
<id>8328bbc57dccbcbd834f822c2c9c70bd2ad199eb</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix #1679: "0x" was taken as a valid integer literal.</title>
<updated>2008-01-19T19:27:05+00:00</updated>
<author>
<name>Georg Brandl</name>
<email>georg@python.org</email>
</author>
<published>2008-01-19T19:27:05+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=14404b68d8c5a501a2f5ee6f45494865b7b38276'/>
<id>14404b68d8c5a501a2f5ee6f45494865b7b38276</id>
<content type='text'>
Fixes the tokenizer, tokenize.py and int() to reject this.
Patches by Malte Helmert.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes the tokenizer, tokenize.py and int() to reject this.
Patches by Malte Helmert.
</pre>
</div>
</content>
</entry>
<entry>
<title>Forward-port of r52136,52138: a review of overflow-detecting code.</title>
<updated>2006-10-04T12:17:45+00:00</updated>
<author>
<name>Armin Rigo</name>
<email>arigo@tunes.org</email>
</author>
<published>2006-10-04T12:17:45+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=7ccbca93a27e22f0b06316b0d9760fbf7b19cbda'/>
<id>7ccbca93a27e22f0b06316b0d9760fbf7b19cbda</id>
<content type='text'>
* unified the way intobject, longobject and mystrtoul handle
  values around -sys.maxint-1.

* in general, trying to entierely avoid overflows in any computation
  involving signed ints or longs is extremely involved.  Fixed a few
  simple cases where a compiler might be too clever (but that's all
  guesswork).

* more overflow checks against bad data in marshal.c.

* 2.5 specific: fixed a number of places that were still confusing int
  and Py_ssize_t.  Some of them could potentially have caused
  "real-world" breakage.

* list.pop(x): fixing overflow issues on x was messy.  I just reverted
  to PyArg_ParseTuple("n"), which does the right thing.  (An obscure
  test was trying to give a Decimal to list.pop()... doesn't make
  sense any more IMHO)

* trying to write a few tests...
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* unified the way intobject, longobject and mystrtoul handle
  values around -sys.maxint-1.

* in general, trying to entierely avoid overflows in any computation
  involving signed ints or longs is extremely involved.  Fixed a few
  simple cases where a compiler might be too clever (but that's all
  guesswork).

* more overflow checks against bad data in marshal.c.

* 2.5 specific: fixed a number of places that were still confusing int
  and Py_ssize_t.  Some of them could potentially have caused
  "real-world" breakage.

* list.pop(x): fixing overflow issues on x was messy.  I just reverted
  to PyArg_ParseTuple("n"), which does the right thing.  (An obscure
  test was trying to give a Decimal to list.pop()... doesn't make
  sense any more IMHO)

* trying to write a few tests...
</pre>
</div>
</content>
</entry>
<entry>
<title>Bug #1521947:  possible bug in mystrtol.c with recent gcc.</title>
<updated>2006-07-27T01:14:53+00:00</updated>
<author>
<name>Tim Peters</name>
<email>tim.peters@gmail.com</email>
</author>
<published>2006-07-27T01:14:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=bc24eee333126a313bfe42381050a49ecbbc8bbe'/>
<id>bc24eee333126a313bfe42381050a49ecbbc8bbe</id>
<content type='text'>
In general, C doesn't define anything about what happens when
an operation on a signed integral type overflows, and PyOS_strtol()
did several formally undefined things of that nature on signed
longs.  Some version of gcc apparently tries to exploit that now,
and PyOS_strtol() could fail to detect overflow then.

Tried to repair all that, although it seems at least as likely to me
that we'll get screwed by bad platform definitions for LONG_MIN
and/or LONG_MAX now.  For that reason, I don't recommend backporting
this.

Note that I have no box on which this makes a lick of difference --
can't really test it, except to note that it didn't break anything
on my boxes.

Silent change:  PyOS_strtol() used to return the hard-coded 0x7fffffff
in case of overflow.  Now it returns LONG_MAX.  They're the same only on
32-bit boxes (although C doesn't guarantee that either ...).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In general, C doesn't define anything about what happens when
an operation on a signed integral type overflows, and PyOS_strtol()
did several formally undefined things of that nature on signed
longs.  Some version of gcc apparently tries to exploit that now,
and PyOS_strtol() could fail to detect overflow then.

Tried to repair all that, although it seems at least as likely to me
that we'll get screwed by bad platform definitions for LONG_MIN
and/or LONG_MAX now.  For that reason, I don't recommend backporting
this.

Note that I have no box on which this makes a lick of difference --
can't really test it, except to note that it didn't break anything
on my boxes.

Silent change:  PyOS_strtol() used to return the hard-coded 0x7fffffff
in case of overflow.  Now it returns LONG_MAX.  They're the same only on
32-bit boxes (although C doesn't guarantee that either ...).
</pre>
</div>
</content>
</entry>
<entry>
<title>On 64 bit systems, int literals that use less than 64 bits are now ints</title>
<updated>2006-07-09T22:14:42+00:00</updated>
<author>
<name>Neal Norwitz</name>
<email>nnorwitz@gmail.com</email>
</author>
<published>2006-07-09T22:14:42+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=28746aba9bf636d03eb1c1c5f4550c6f2dbf5300'/>
<id>28746aba9bf636d03eb1c1c5f4550c6f2dbf5300</id>
<content type='text'>
rather than longs.  This also fixes the test for eval(-sys.maxint - 1).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
rather than longs.  This also fixes the test for eval(-sys.maxint - 1).
</pre>
</div>
</content>
</entry>
<entry>
<title>Patch #1495999: Part two of Windows CE changes.</title>
<updated>2006-06-10T12:23:46+00:00</updated>
<author>
<name>Martin v. Löwis</name>
<email>martin@v.loewis.de</email>
</author>
<published>2006-06-10T12:23:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cpython-git.git/commit/?id=0e8bd7e1ccf7f47bc0bb920af899c77669016d3d'/>
<id>0e8bd7e1ccf7f47bc0bb920af899c77669016d3d</id>
<content type='text'>
- update header checks, using autoconf
- provide dummies for getenv, environ, and GetVersion
- adjust MSC_VER check in socketmodule.c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- update header checks, using autoconf
- provide dummies for getenv, environ, and GetVersion
- adjust MSC_VER check in socketmodule.c
</pre>
</div>
</content>
</entry>
</feed>
