-
Notifications
You must be signed in to change notification settings - Fork 85
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
Document that Either should not be used in new code #1699
Conversation
@@ -238,10 +238,11 @@ Traits | |||
.. autoclass:: ToolbarButton | |||
:show-inheritance: | |||
|
|||
.. autoclass:: Either | |||
.. autoclass:: Union |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Deliberately swapping the order so that Union
appears before Either
in the docs.
There's also a drive-by fix here: :show-inheritance:
was missing for Union
, for no reason that I can discern.
@@ -269,7 +269,7 @@ the table. | |||
.. index:: PythonValue(), Range(), ReadOnly(), Regex() | |||
.. index:: Set() String(), This, Time() | |||
.. index:: ToolbarButton(), true, Tuple(), Type() | |||
.. index:: undefined, UUID(), ValidatedTuple(), WeakRef() | |||
.. index:: undefined, Union(), UUID(), ValidatedTuple(), WeakRef() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Another drive-by fix: Union
was missing from this list of index entries.
@@ -408,7 +408,7 @@ the table. | |||
| Union | Union( *val1*\ [, *val2*, ..., *valN*, | | |||
| | \*\*\ *metadata*] ) | | |||
+------------------+----------------------------------------------------------+ | |||
| UUID [4]_ | UUID( [\*\*\ *metadata*] ) | | |||
| UUID | UUID( [\*\*\ *metadata*] ) | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Dropped the [4]
footnote, which talked about Python 2.5; I've re-used it for Either
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick: footnote 4 comes before footnote 3 (attached to Function
and Method
) in the text.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks; fixed. At the same time, I fixed that the current footnotes start from the third natural number, rather than the second as is more conventional.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple of nit-picky sorts of comments.
@@ -408,7 +408,7 @@ the table. | |||
| Union | Union( *val1*\ [, *val2*, ..., *valN*, | | |||
| | \*\*\ *metadata*] ) | | |||
+------------------+----------------------------------------------------------+ | |||
| UUID [4]_ | UUID( [\*\*\ *metadata*] ) | | |||
| UUID | UUID( [\*\*\ *metadata*] ) | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick: footnote 4 comes before footnote 3 (attached to Function
and Method
) in the text.
This PR adds notes to the user manual and API documentation to discourage users from using Either in new code. (Union should be preferred.) (cherry picked from commit c5cfdde)
This PR adds notes to the user manual and API documentation to discourage users from using
Either
in new code. (Union
should be preferred.)Closes #1610