homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author wim.glenn
Recipients docs@python, wim.glenn
Date 2015年04月17日.07:22:57
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1429255378.08.0.140067438597.issue23986@psf.upfronthosting.co.za>
In-reply-to
Content
The comparisons section of the python 2 docs says:
--- 
https://docs.python.org/2/reference/expressions.html#comparisons
For the list and tuple types, x in y is true if and only if there exists an index i such that x == y[i] is true.
---
But it's not strictly speaking correct. Simplest counter-example:
x = float('nan')
y = [x]
The python 3 docs instead mention correct equivalent which is 
any(x is e or x == e for e in y)
History
Date User Action Args
2015年04月17日 07:22:58wim.glennsetrecipients: + wim.glenn, docs@python
2015年04月17日 07:22:58wim.glennsetmessageid: <1429255378.08.0.140067438597.issue23986@psf.upfronthosting.co.za>
2015年04月17日 07:22:58wim.glennlinkissue23986 messages
2015年04月17日 07:22:57wim.glenncreate

AltStyle によって変換されたページ (->オリジナル) /