New submission from Alex Orange:
The documentation at http://docs.python.org/2/c-api/typeobj.html#PySequenceMethods is missing sq_slice between sq_item and sq_ass_item. This will mess up anyone trying to use anything after sq_item (that isn't using designated initializers).
---------- assignee: docs@python components: Documentation messages: 183779 nosy: Alex.Orange, docs@python priority: normal severity: normal status: open title: Error in C API documentation of PySequenceMethods versions: Python 2.7
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Changes by Mike Hoy mhoy09@gmail.com:
---------- nosy: +mikehoy
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Mike Hoy added the comment:
Looking through Include/object.h I see that sq_slice is now:
void *was_sq_slice. Can anyone provide any clarification as to where I can find info about sq_slice?
----------
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Alex Orange added the comment:
If you look at the 2.7.3 version of that file: http://hg.python.org/cpython/file/70274d53c1dd/Include/object.h it has more information. It is a ssizessizeargfunc. I assume it passes the lower and upper bound and expects back a subsequence.
----------
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Alex Orange added the comment:
Just to clarify though, that is entirely an assumption as to how it's supposed to be used.
----------
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Changes by Jesús Cea Avión jcea@jcea.es:
---------- nosy: +jcea
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Mike Hoy added the comment:
I was looking at 3.4 files. You're right it is in 2.7. Guess you have all the info you need to make a patch for it then?
ssizessizeargfunc PySequenceMethods.sq_slice
It passes the lower and upper bound and expects back a subsequence.
Or is there more to it than that? I cannot for the life of me make any sense out of it. Here I was sitting looking at this thinking it would be very easy doc fix for me but in the end I think I'll bow out.
----------
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Changes by Ezio Melotti ezio.melotti@gmail.com:
---------- nosy: +benjamin.peterson, ezio.melotti stage: -> needs patch type: -> enhancement
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Alex Orange added the comment:
I must admit I'm a little new to the development side of things. Can someone point me at a repo or something that the documentation files are in? I'm sort of guessing that the html is the processed output of something.
----------
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Ezio Melotti added the comment:
See http://docs.python.org/devguide/ and the Doc/c-api dir in the CPython repo.
----------
_______________________________________ Python tracker report@bugs.python.org http://bugs.python.org/issue17387 _______________________________________
Serhiy Storchaka storchaka+cpython@gmail.com added the comment:
Python 2.7 is no longer supported.
---------- nosy: +serhiy.storchaka resolution: -> out of date stage: needs patch -> resolved status: open -> closed
_______________________________________ Python tracker report@bugs.python.org https://bugs.python.org/issue17387 _______________________________________