Skip to content

Commit f0f3efc

Browse files
authored
DOC: fix PR07,SA01 for pandas.api.types.is_iterator (#60142)
1 parent d25b3c2 commit f0f3efc

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

ci/code_checks.sh

-1
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
8585
-i "pandas.Timestamp.resolution PR02" \
8686
-i "pandas.Timestamp.tzinfo GL08" \
8787
-i "pandas.Timestamp.year GL08" \
88-
-i "pandas.api.types.is_iterator PR07,SA01" \
8988
-i "pandas.api.types.is_re_compilable PR07,SA01" \
9089
-i "pandas.api.types.pandas_dtype PR07,RT03,SA01" \
9190
-i "pandas.arrays.ArrowExtensionArray PR07,SA01" \

pandas/_libs/lib.pyx

+8
Original file line numberDiff line numberDiff line change
@@ -259,15 +259,23 @@ def is_iterator(obj: object) -> bool:
259259
Check if the object is an iterator.
260260

261261
This is intended for generators, not list-like objects.
262+
This method checks whether the passed object is an iterator. It
263+
returns `True` if the object is an iterator, and `False` otherwise.
262264

263265
Parameters
264266
----------
265267
obj : The object to check
268+
The object to check for iterator type.
266269

267270
Returns
268271
-------
269272
is_iter : bool
270273
Whether `obj` is an iterator.
274+
`True` if the object is of iterator type, otherwise `False`.
275+
276+
See Also
277+
--------
278+
api.types.is_list_like : Check if the input is list-like.
271279

272280
Examples
273281
--------

0 commit comments

Comments
 (0)