]> granicus.if.org Git - python/commitdiff
Issues #25909, #28211: Restored correct documentation of PyMapping_Items,
authorSerhiy Storchaka <storchaka@gmail.com>
Mon, 26 Sep 2016 17:52:41 +0000 (20:52 +0300)
committerSerhiy Storchaka <storchaka@gmail.com>
Mon, 26 Sep 2016 17:52:41 +0000 (20:52 +0300)
PyMapping_Keys and PyMapping_Values.  Based on patch by Xiang Zhang.

Doc/c-api/mapping.rst
Include/abstract.h

index fe601b605b13837f1c38ccb8dae4b19037dc6132..a71e94283776e96b9eaa4f87de1eb020a72aa6d1 100644 (file)
@@ -50,21 +50,20 @@ Mapping Protocol
 
 .. c:function:: PyObject* PyMapping_Keys(PyObject *o)
 
-   On success, return a list, a tuple or a dictionary view in case of a dict,
-   of the keys in object *o*. On failure, return *NULL*.
+   On success, return a list or tuple of the keys in object *o*.  On failure,
+   return *NULL*.
 
 
 .. c:function:: PyObject* PyMapping_Values(PyObject *o)
 
-   On success, return a list, a tuple or a dictionary view in case of a dict, of
-   the values in object *o*. On failure, return *NULL*.
+   On success, return a list or tuple of the values in object *o*.  On failure,
+   return *NULL*.
 
 
 .. c:function:: PyObject* PyMapping_Items(PyObject *o)
 
-   On success, return a list, a tuple or a dictionary view in case of a dict, of
-   the items in object *o*, where each item is a tuple containing a key-value
-   pair.  On failure, return *NULL*.
+   On success, return a list or tuple of the items in object *o*, where each item
+   is a tuple containing a key-value pair.  On failure, return *NULL*.
 
 
 .. c:function:: PyObject* PyMapping_GetItemString(PyObject *o, const char *key)
index 438610ba98585a6e6e421b7d0558095fa84a0611..36df5a7ce2a2d30cbb63f071905925d358a52e5c 100644 (file)
@@ -1216,23 +1216,23 @@ xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx*/
      PyAPI_FUNC(PyObject *) PyMapping_Keys(PyObject *o);
 
        /*
-     On success, return a list, a tuple or a dictionary view in case of a dict,
-     of the keys in object o. On failure, return NULL.
+     On success, return a list or tuple of the keys in object o.
+     On failure, return NULL.
        */
 
      PyAPI_FUNC(PyObject *) PyMapping_Values(PyObject *o);
 
        /*
-     On success, return a list, a tuple or a dictionary view in case of a dict,
-     of the values in object o. On failure, return NULL.
+     On success, return a list or tuple of the values in object o.
+     On failure, return NULL.
        */
 
      PyAPI_FUNC(PyObject *) PyMapping_Items(PyObject *o);
 
        /*
-     On success, return a list, a tuple or a dictionary view in case of a dict,
-     of the items in object o, where each item is a tuple containing a key-value
-     pair. On failure, return NULL.
+     On success, return a list or tuple of the items in object o,
+     where each item is a tuple containing a key-value pair.
+     On failure, return NULL.
 
        */