Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bpo-21056: Document return type of next method of csv reader #146

Merged
merged 3 commits into from May 23, 2017
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 4 additions & 2 deletions Doc/library/csv.rst
Expand Up @@ -401,8 +401,10 @@ Reader objects (:class:`DictReader` instances and objects returned by the

.. method:: csvreader.__next__()

Return the next row of the reader's iterable object as a list, parsed according
to the current dialect. Usually you should call this as ``next(reader)``.
Return the next row of the reader's iterable object as a list (if the object
was returned from ``reader()``) or a dict (if it is a ``DictReader``), parsed
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

reader() is not very clear here. "[...] from :func:`reader`" would be much clearer.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if it is a :class:`DictReader` instance

according to the current dialect. Usually you should call this as
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add two spaces after a full-stop:

[...] dialect.  Usually [...]

``next(reader)``.


Reader objects have the following public attributes:
Expand Down