Skip to content

Commit d618c8c

Browse files
aktechMariatta
authored andcommitted
bpo-21056: Document return type of next method of csv reader (#146)
1 parent 6b4be19 commit d618c8c

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Doc/library/csv.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -401,8 +401,10 @@ Reader objects (:class:`DictReader` instances and objects returned by the
401401

402402
.. method:: csvreader.__next__()
403403

404-
Return the next row of the reader's iterable object as a list, parsed according
405-
to the current dialect. Usually you should call this as ``next(reader)``.
404+
Return the next row of the reader's iterable object as a list (if the object
405+
was returned from :func:`reader`) or a dict (if it is a :class:`DictReader`
406+
instance), parsed according to the current dialect. Usually you should call
407+
this as ``next(reader)``.
406408

407409

408410
Reader objects have the following public attributes:

0 commit comments

Comments
 (0)