]> granicus.if.org Git - python/commitdiff
Bug #1629125: fix wrong data type (int -> Py_ssize_t) in PyDict_Next docs.
authorGeorg Brandl <georg@python.org>
Wed, 17 Jan 2007 21:19:58 +0000 (21:19 +0000)
committerGeorg Brandl <georg@python.org>
Wed, 17 Jan 2007 21:19:58 +0000 (21:19 +0000)
Doc/api/concrete.tex
Misc/NEWS

index 33b04d48616118bb958b263c3f9419a2fa16011a..e2d3e52f53428ae92f9f9cae7d87aaab6dac8060 100644 (file)
@@ -2082,7 +2082,7 @@ format.
 
 \begin{verbatim}
 PyObject *key, *value;
-int pos = 0;
+Py_ssize_t pos = 0;
 
 while (PyDict_Next(self->dict, &pos, &key, &value)) {
     /* do something interesting with the values... */
@@ -2097,7 +2097,7 @@ while (PyDict_Next(self->dict, &pos, &key, &value)) {
 
 \begin{verbatim}
 PyObject *key, *value;
-int pos = 0;
+Py_ssize_t pos = 0;
 
 while (PyDict_Next(self->dict, &pos, &key, &value)) {
     int i = PyInt_AS_LONG(value) + 1;
index 3d742f577aa28e7c8f1834be13885f770ffacb6b..cf9133e9249ca484d3d7e242c4798fe9f17ecf12 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -403,6 +403,9 @@ Tools
 Documentation
 -------------
 
+- Bug #1629125: fix wrong data type (int -> Py_ssize_t) in PyDict_Next
+  docs.
+
 - Bug #1565919: document set types in the Language Reference.
 
 - Bug #1546052: clarify that PyString_FromString(AndSize) copies the