Skip to content

Commit 42eb7a0

Browse files
authored
Use raw string for docstrings containing escape sequences (#455)
1 parent 6a35bc1 commit 42eb7a0

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

Diff for: spec/API_specification/array_api/creation_functions.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def arange(start: Union[int, float], /, stop: Optional[Union[int, float]] = None
2929
"""
3030

3131
def asarray(obj: Union[array, bool, int, float, complex, NestedSequence, SupportsBufferProtocol], /, *, dtype: Optional[dtype] = None, device: Optional[device] = None, copy: Optional[bool] = None) -> array:
32-
"""
32+
r"""
3333
Convert the input to an array.
3434
3535
Parameters

Diff for: spec/API_specification/array_api/elementwise_functions.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -598,7 +598,7 @@ def floor(x: array, /) -> array:
598598
"""
599599

600600
def floor_divide(x1: array, x2: array, /) -> array:
601-
"""
601+
r"""
602602
Rounds the result of dividing each element ``x1_i`` of the input array ``x1`` by the respective element ``x2_i`` of the input array ``x2`` to the greatest (i.e., closest to `+infinity`) integer-value number that is not greater than the division result.
603603
604604
.. note::

Diff for: spec/API_specification/array_api/linalg.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -459,7 +459,7 @@ def vecdot(x1: array, x2: array, /, *, axis: int = None) -> array:
459459
"""
460460

461461
def vector_norm(x: array, /, *, axis: Optional[Union[int, Tuple[int, ...]]] = None, keepdims: bool = False, ord: Union[int, float, Literal[inf, -inf]] = 2) -> array:
462-
"""
462+
r"""
463463
Computes the vector norm of a vector (or batch of vectors) ``x``.
464464
465465
Parameters

0 commit comments

Comments
 (0)