This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: incorrect signature in doc for PyByteArray_Resize
Type: Stage: resolved
Components: Documentation Versions: Python 3.1, Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: ezio.melotti Nosy List: drukker, ezio.melotti, georg.brandl
Priority: low Keywords:

Created on 2009-09-11 09:24 by drukker, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (4)
msg92506 - (view) Author: Derk Drukker (drukker) Date: 2009-09-11 09:24
in Doc/c-api/bytearray.rst:

    PyObject* PyByteArray_Resize(PyObject *bytearray, Py_ssize_t len)

should be:

    int PyByteArray_Resize(PyObject *bytearray, Py_ssize_t len)

as per Include/bytearrayobject.h
msg92661 - (view) Author: Ezio Melotti (ezio.melotti) * (Python committer) Date: 2009-09-16 02:40
The PyByteArrayIter_Type is also missing, and the arg names of several
functions don't match the ones in the C source in Objects/bytesobject.c .
It might also be a good idea to add sub-headers in the doc to group
these functions in the same way they are grouped in the .h file (i.e.
Type Object, Type check macros, Direct API functions, Macros).
msg92672 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2009-09-16 09:34
I don't think the iterator type needs to be documented; many other such
iter types aren't.

Also, the argument names needn't match (since C doesn't have the notion
of keyword arguments).  They can be changed in the docs to be more
obvious than what the programmer chose :)

Would you like to fix the rest?
msg92882 - (view) Author: Ezio Melotti (ezio.melotti) * (Python committer) Date: 2009-09-20 07:24
Fixed in r74958 (trunk), r74959 (release26-maint), r74960 (py3k) and
r74961 (release31-maint).
History
Date User Action Args
2022-04-11 14:56:52adminsetgithub: 51130
2009-09-20 07:24:44ezio.melottisetstatus: open -> closed
resolution: accepted -> fixed
messages: + msg92882

stage: resolved
2009-09-16 09:34:43georg.brandlsetassignee: georg.brandl -> ezio.melotti
messages: + msg92672
2009-09-16 02:40:34ezio.melottisetpriority: low

nosy: + ezio.melotti
messages: + msg92661

resolution: accepted
2009-09-11 09:24:43drukkercreate