diff options
author | Raymond Hettinger <python@rcn.com> | 2002-08-23 18:10:54 (GMT) |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2002-08-23 18:10:54 (GMT) |
commit | fa8dd5f40781d8670824d8ec94e37e4f6e075135 (patch) | |
tree | 3ae5fbe4f4d05097b4586833f73cf9f64549885e /Doc/lib/libsets.tex | |
parent | 7c7efe90737d4636633127a95a6cab1a55d57cf4 (diff) | |
download | cpython-fa8dd5f40781d8670824d8ec94e37e4f6e075135.zip cpython-fa8dd5f40781d8670824d8ec94e37e4f6e075135.tar.gz cpython-fa8dd5f40781d8670824d8ec94e37e4f6e075135.tar.bz2 |
Fix markup and punctuation
Diffstat (limited to 'Doc/lib/libsets.tex')
-rw-r--r-- | Doc/lib/libsets.tex | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Doc/lib/libsets.tex b/Doc/lib/libsets.tex index 865a9a1..5f199a0 100644 --- a/Doc/lib/libsets.tex +++ b/Doc/lib/libsets.tex @@ -33,7 +33,7 @@ abstract class useful for determining whether something is a set: The set classes are implemented using dictionaries. As a result, sets cannot contain mutable elements such as lists or dictionaries. However, they can contain immutable collections such as tuples or -instances of \class(ImmutableSet). For convenience in implementing +instances of \class{ImmutableSet}. For convenience in implementing sets of sets, inner sets are automatically converted to immutable form, for example, \code{Set([Set(['dog'])])} is transformed to \code{Set([ImmutableSet(['dog'])])}. @@ -140,8 +140,8 @@ but not found in \class{ImmutableSet}: \lineii{\var{s}.remove(\var{x})} {Remove element \var{x} from set \var{s}} \lineii{\var{s}.discard(\var{x})} - {Removes element \var{x} from set \var{s} like \var{s}.remove(\var{x}) - but does not raise a KeyError if \var{x} is not in \var{s}} + {Removes element \var{x} from set \var{s}. Like \var{s}.remove(\var{x}) + but does not raise KeyError if \var{x} is not in \var{s}} \lineii{\var{s}.pop()} {Remove and return an element from \var{s}; no guarantee is made about which element is removed} @@ -212,6 +212,6 @@ method which returns the \class{Set} object wrapped by a new class The two mechanisms for adding hashability are normally invisible to the user; however, a conflict can arise in a multi-threaded environment -where one thread is updating a Set while another has temporarily wrapped it +where one thread is updating a set while another has temporarily wrapped it in \class{_TemporarilyImmutableSet}. In other words, sets of mutable sets are not thread-safe. |