mirror of
https://github.com/python/cpython.git
synced 2025-08-22 09:45:06 +00:00
bpo-38580: Document that select() accepts iterables, not just sequences (GH-16832)
This commit is contained in:
parent
cba5031510
commit
372ee27d49
3 changed files with 8 additions and 8 deletions
|
@ -239,7 +239,7 @@ select.select
|
|||
|
||||
Wait until one or more file descriptors are ready for some kind of I/O.
|
||||
|
||||
The first three arguments are sequences of file descriptors to be waited for:
|
||||
The first three arguments are iterables of file descriptors to be waited for:
|
||||
rlist -- wait until ready for reading
|
||||
wlist -- wait until ready for writing
|
||||
xlist -- wait for an "exceptional condition"
|
||||
|
@ -264,7 +264,7 @@ descriptors can be used.
|
|||
static PyObject *
|
||||
select_select_impl(PyObject *module, PyObject *rlist, PyObject *wlist,
|
||||
PyObject *xlist, PyObject *timeout_obj)
|
||||
/*[clinic end generated code: output=2b3cfa824f7ae4cf input=177e72184352df25]*/
|
||||
/*[clinic end generated code: output=2b3cfa824f7ae4cf input=e467f5d68033de00]*/
|
||||
{
|
||||
#ifdef SELECT_USES_HEAP
|
||||
pylist *rfd2obj, *wfd2obj, *efd2obj;
|
||||
|
@ -320,7 +320,7 @@ select_select_impl(PyObject *module, PyObject *rlist, PyObject *wlist,
|
|||
}
|
||||
#endif /* SELECT_USES_HEAP */
|
||||
|
||||
/* Convert sequences to fd_sets, and get maximum fd number
|
||||
/* Convert iterables to fd_sets, and get maximum fd number
|
||||
* propagates the Python exception set in seq2set()
|
||||
*/
|
||||
rfd2obj[0].sentinel = -1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue