Skip to content

Commit

Permalink
DOC: Fix some document build errors about rst markups
Browse files Browse the repository at this point in the history
[skip cirrus] [skip azp] [skip actions]
  • Loading branch information
F3eQnxN3RriK authored and rgommers committed Mar 3, 2024
1 parent 54b174f commit 6e9016b
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions doc/release/upcoming_changes/25168.change.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
New ``copy`` keyword meaning for `numpy.array` and `numpy.asarray`
------------------------------------------------------------------
Now `numpy.array` and `numpy.asarray` support three values for ``copy`` parameter:

* ``None`` - A copy will only be made if it is necessary.
* ``True`` - Always make a copy.
* ``False`` - Never make a copy. If a copy is required a ``ValueError`` is raised.
Expand Down
1 change: 1 addition & 0 deletions doc/release/upcoming_changes/25866.c_api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ New C-API import functions
We have now added ``PyArray_ImportNumPyAPI`` and ``PyUFunc_ImportUFuncAPI``
as static inline functions to import the NumPy C-API tables.
The new functions have two advantages over `import_array` and `import_ufunc`:

- They check whether the import was already performed and are light-weight
if not, allowing to add them judiciously (although this is not preferable
in most cases).
Expand Down
2 changes: 1 addition & 1 deletion doc/source/reference/c-api/array.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3737,7 +3737,7 @@ the C-API is needed then some additional steps must be taken.
.. versionadded:: 2.0
This function is backported in the ``npy_2_compat.h`` header.
.. c:macro:: void import_array(void)
.. c:macro:: import_array(void)
This function must be called in the initialization section of a
module that will make use of the C-API. It imports the module
Expand Down
2 changes: 1 addition & 1 deletion doc/source/reference/c-api/ufunc.rst
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ Importing the API
This function mainly checks for ``PyUFunc_API == NULL`` so it can be
manually backported if desired.
.. c:macro:: void import_ufunc(void)
.. c:macro:: import_ufunc(void)
These are the constants and functions for accessing the ufunc
C-API from extension modules in precisely the same way as the
Expand Down

0 comments on commit 6e9016b

Please sign in to comment.