summaryrefslogtreecommitdiffstats
path: root/Doc/ref5.tex
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1993-05-12 08:53:36 (GMT)
committerGuido van Rossum <guido@python.org>1993-05-12 08:53:36 (GMT)
commitb2c6556fb0d309a04e37c2c9937fed16284cd00f (patch)
treebc941f86ad5db39a0ee4be9f590c27dd40b53c2e /Doc/ref5.tex
parent6ac258d381b5300e3ec935404a111e8dff4617d4 (diff)
downloadcpython-b2c6556fb0d309a04e37c2c9937fed16284cd00f.zip
cpython-b2c6556fb0d309a04e37c2c9937fed16284cd00f.tar.gz
cpython-b2c6556fb0d309a04e37c2c9937fed16284cd00f.tar.bz2
Lots of small changes collected over months...
Diffstat (limited to 'Doc/ref5.tex')
-rw-r--r--Doc/ref5.tex13
1 files changed, 7 insertions, 6 deletions
diff --git a/Doc/ref5.tex b/Doc/ref5.tex
index 7857e95..59ba90a 100644
--- a/Doc/ref5.tex
+++ b/Doc/ref5.tex
@@ -176,8 +176,9 @@ The key/datum pairs are evaluated from left to right to define the
entries of the dictionary: each key object is used as a key into the
dictionary to store the corresponding datum.
-Keys must be strings, otherwise a \verb\TypeError\ exception is
-raised. Clashes between duplicate keys are not detected; the last
+Restrictions on the types of the key values are listed earlier in
+section \ref{types}.
+Clashes between duplicate keys are not detected; the last
datum (textually rightmost in the display) stored for a given key
value prevails.
\exindex{TypeError}
@@ -565,10 +566,10 @@ corresponding items.
Mappings (dictionaries) are compared through lexicographic
comparison of their sorted (key, value) lists.%
\footnote{This is expensive since it requires sorting the keys first,
-but about the only sensible definition. It was tried to compare
-dictionaries by identity only, but this caused surprises because
-people expected to be able to test a dictionary for emptiness by
-comparing it to {\tt \{\}}.}
+but about the only sensible definition. An earlier version of Python
+compared dictionaries by identity only, but this caused surprises
+because people expected to be able to test a dictionary for emptiness
+by comparing it to {\tt \{\}}.}
\item
Most other types compare unequal unless they are the same object;