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

DOC: Added example of multi-line instruction in Examples section of a docstring. #10880

Closed

Conversation

pvanmulbregt
Copy link
Contributor

Added an example showing how to use multi-line commands in the Examples section of the docstring.

@@ -415,6 +415,14 @@ The sections of the docstring are:
>>> np.add([1, 2], [3, 4])
array([4, 6])

An instruction may be split across multiple lines, with each line after
Copy link
Member

Choose a reason for hiding this comment

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

"instruction" seems like a weird description. Perhaps "An expression", "A statement", or even just "The example code"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Indeed. Thanks.

@mattip
Copy link
Member

mattip commented Apr 11, 2018

This actually belongs in numpy/numpydoc in doc/format.rst, this file is a different version of the documentation there. In PR #10878 I am trying to remove the redundancy by removing most of the content of doc/HOWTO_DOCUMENT.rst.txt

@pvanmulbregt
Copy link
Contributor Author

Added a new PR to numpy/numpydoc (numpy/numpydoc#168) to put the change in doc/format.rst. If that's the right place for this particular modification, then this PR can be closed without further action.

@mattip
Copy link
Member

mattip commented Apr 11, 2018

Thanks, yes that should do it. I will leave this open until #10878 is merged

@mattip
Copy link
Member

mattip commented Apr 30, 2018

numpy/numpydoc#168 was merged, thanks

@mattip mattip closed this Apr 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants