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

Fix wording for comparison operators. #736

Merged
merged 5 commits into from
Jan 25, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion spec/2021.12/API_specification/array_object.rst
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,8 @@ A conforming implementation of the array API standard must provide and support a
- `operator.ne(x1, x2) <https://docs.python.org/3/library/operator.html#operator.ne>`_
- `operator.__ne__(x1, x2) <https://docs.python.org/3/library/operator.html#operator.__ne__>`_

Comparison operators should be defined for arrays having any data type.
:meth:`.array.__lt__`, :meth:`.array.__le__`, :meth:`.array.__gt__`, :meth:`.array.__ge__` are only defined for arrays having real-valued data types. Other comparison operators should be defined for arrays having any data type.
hameerabbasi marked this conversation as resolved.
Show resolved Hide resolved
For backward compatibility, conforming implementations may support complex numbers; however, inequality comparison of complex numbers is unspecified and thus implementation-dependent.

In-place Operators
~~~~~~~~~~~~~~~~~~
Expand Down
3 changes: 2 additions & 1 deletion spec/2022.12/API_specification/array_object.rst
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,8 @@ A conforming implementation of the array API standard must provide and support a
- `operator.ne(x1, x2) <https://docs.python.org/3/library/operator.html#operator.ne>`_
- `operator.__ne__(x1, x2) <https://docs.python.org/3/library/operator.html#operator.__ne__>`_

Comparison operators should be defined for arrays having any data type.
:meth:`.array.__lt__`, :meth:`.array.__le__`, :meth:`.array.__gt__`, :meth:`.array.__ge__` are only defined for arrays having real-valued data types. Other comparison operators should be defined for arrays having any data type.
For backward compatibility, conforming implementations may support complex numbers; however, inequality comparison of complex numbers is unspecified and thus implementation-dependent (see :ref:`complex-number-ordering`).
kgryte marked this conversation as resolved.
Show resolved Hide resolved

In-place Operators
~~~~~~~~~~~~~~~~~~
Expand Down
3 changes: 2 additions & 1 deletion spec/draft/API_specification/array_object.rst
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,8 @@ A conforming implementation of the array API standard must provide and support a
- `operator.ne(x1, x2) <https://docs.python.org/3/library/operator.html#operator.ne>`_
- `operator.__ne__(x1, x2) <https://docs.python.org/3/library/operator.html#operator.__ne__>`_

Comparison operators should be defined for arrays having any data type.
:meth:`.array.__lt__`, :meth:`.array.__le__`, :meth:`.array.__gt__`, :meth:`.array.__ge__` are only defined for arrays having real-valued data types. Other comparison operators should be defined for arrays having any data type.
For backward compatibility, conforming implementations may support complex numbers; however, inequality comparison of complex numbers is unspecified and thus implementation-dependent (see :ref:`complex-number-ordering`).
kgryte marked this conversation as resolved.
Show resolved Hide resolved

In-place Operators
~~~~~~~~~~~~~~~~~~
Expand Down
Loading