diff -r 746cf48dca08 -r da035bbeb296 Doc/library/stdtypes.rst --- a/Doc/library/stdtypes.rst Fri Oct 08 20:46:09 2010 +0200 +++ b/Doc/library/stdtypes.rst Sat Oct 09 00:23:06 2010 +0200 @@ -2208,33 +2208,17 @@ Keys views are set-like since their entries are unique and hashable. If all -values are hashable, so that (key, value) pairs are unique and hashable, then -the items view is also set-like. (Values views are not treated as set-like -since the entries are generally not unique.) Then these set operations are -available ("other" refers either to another view or a set): - -.. describe:: dictview & other - - Return the intersection of the dictview and the other object as a new set. - -.. describe:: dictview | other - - Return the union of the dictview and the other object as a new set. - -.. describe:: dictview - other - - Return the difference between the dictview and the other object (all elements - in *dictview* that aren't in *other*) as a new set. +values are hashable, so that ``(key, value)`` pairs are unique and hashable, +then the items view is also set-like. (Values views are not treated as set-like +since the entries are generally not unique.) For set-like views, all of the +operations defined for the abstract base class :class:`Collection.Set` are +available (for example, ``==``, ``<``, or ``>=``), and also it's provided: .. describe:: dictview ^ other Return the symmetric difference (all elements either in *dictview* or - *other*, but not in both) of the dictview and the other object as a new set. - -.. method:: dictview.isdisjoint(other) - - Return True if the view has no elements in common with *other*. Sets are - disjoint if and only if their intersection is the empty set. + *other*, but not in both) of the dictview and the other object (either a set + or another view) as a new set. An example of dictionary view usage:: diff -r 746cf48dca08 -r 3c79f689c51f Doc/library/stdtypes.rst --- a/Doc/library/stdtypes.rst Fri Oct 08 20:46:09 2010 +0200 +++ b/Doc/library/stdtypes.rst Sat Oct 09 00:25:18 2010 +0200 @@ -2208,33 +2208,17 @@ Keys views are set-like since their entries are unique and hashable. If all -values are hashable, so that (key, value) pairs are unique and hashable, then -the items view is also set-like. (Values views are not treated as set-like -since the entries are generally not unique.) Then these set operations are -available ("other" refers either to another view or a set): - -.. describe:: dictview & other - - Return the intersection of the dictview and the other object as a new set. - -.. describe:: dictview | other - - Return the union of the dictview and the other object as a new set. - -.. describe:: dictview - other - - Return the difference between the dictview and the other object (all elements - in *dictview* that aren't in *other*) as a new set. +values are hashable, so that ``(key, value)`` pairs are unique and hashable, +then the items view is also set-like. (Values views are not treated as set-like +since the entries are generally not unique.) For set-like views, all of the +operations defined for the abstract base class :class:`Collections.Set` are +available (for example, ``==``, ``<``, or ``>=``), and also it's provided: .. describe:: dictview ^ other Return the symmetric difference (all elements either in *dictview* or - *other*, but not in both) of the dictview and the other object as a new set. - -.. method:: dictview.isdisjoint(other) - - Return True if the view has no elements in common with *other*. Sets are - disjoint if and only if their intersection is the empty set. + *other*, but not in both) of the dictview and the other object (either a set + or another view) as a new set. An example of dictionary view usage::