summaryrefslogtreecommitdiffstats
path: root/Doc/libmd5.tex
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1995-01-04 19:17:34 (GMT)
committerGuido van Rossum <guido@python.org>1995-01-04 19:17:34 (GMT)
commit31cce9737477d924d9e1ea476920df72dab92495 (patch)
tree10314d7aa86f4b8eb8c87a8780d99aa075d45057 /Doc/libmd5.tex
parente5f8b60429655e94fbfb84a039a2b939b1d8556c (diff)
downloadcpython-31cce9737477d924d9e1ea476920df72dab92495.zip
cpython-31cce9737477d924d9e1ea476920df72dab92495.tar.gz
cpython-31cce9737477d924d9e1ea476920df72dab92495.tar.bz2
copyright.tex: Add 1995 to copyright message.
lib.tex: add libimp; remove bogus warning about lineii. libmath.tex: document hypot(). libmd5.tex: rename md5.md5() to md5.new(). libposix.tex: document chown(). libposixfile.tex: openfile() instead of fileopen(). libsocket.tex: document gethostbyaddr(). libtypes.tex: add footnote explaining why readline() keeps the newline. ref3.tex: correct typos, add back*quotes to index. ref4.tex: don't use \verb inside footnote. ref5.tex: explain repr() and str() and add them + back*quotes to index. ref6.tex: correct typo, don't use \verb in footnote. ref7.tex: don't use \verb in footnote.
Diffstat (limited to 'Doc/libmd5.tex')
-rw-r--r--Doc/libmd5.tex14
1 files changed, 10 insertions, 4 deletions
diff --git a/Doc/libmd5.tex b/Doc/libmd5.tex
index edaa727..3e22820 100644
--- a/Doc/libmd5.tex
+++ b/Doc/libmd5.tex
@@ -15,8 +15,8 @@ example will be helpful:
to obtain the digest of the string \code{'abc'}, use \ldots
\bcode\begin{verbatim}
->>> from md5 import md5
->>> m = md5()
+>>> import md5
+>>> m = md5.new()
>>> m.update('abc')
>>> m.digest()
'\220\001P\230<\322O\260\326\226?}(\341\177r'
@@ -25,16 +25,22 @@ to obtain the digest of the string \code{'abc'}, use \ldots
More condensed:
\bcode\begin{verbatim}
->>> md5('abc').digest()
+>>> md5.new('abc').digest()
'\220\001P\230<\322O\260\326\226?}(\341\177r'
\end{verbatim}\ecode
\renewcommand{\indexsubitem}{(in module md5)}
-\begin{funcdesc}{md5}{\optional{arg}}
+
+\begin{funcdesc}{new}{\optional{arg}}
Create a new md5-object. If \var{arg} is present, an initial
\code{update} method is called with \var{arg} as argument.
\end{funcdesc}
+\begin{funcdesc}{md5}{\optional{arg}}
+For backward compatibility reasons, this is an alternative name for the
+\code{new} function.
+\end{funcdesc}
+
An md5-object has the following methods:
\renewcommand{\indexsubitem}{(md5 method)}