File tree Expand file tree Collapse file tree 2 files changed +9
-12
lines changed Expand file tree Collapse file tree 2 files changed +9
-12
lines changed Original file line number Diff line number Diff line change @@ -135,7 +135,7 @@ The :mod:`binascii` module defines the following functions:
135
135
136
136
.. function :: crc32(data[, value])
137
137
138
- Compute CRC-32, the 32-bit checksum of *data *, starting with an
138
+ Compute CRC-32, the unsigned 32-bit checksum of *data *, starting with an
139
139
initial CRC of *value *. The default initial CRC is zero. The algorithm
140
140
is consistent with the ZIP file checksum. Since the algorithm is designed for
141
141
use as a checksum algorithm, it is not suitable for use as a general hash
@@ -149,9 +149,8 @@ The :mod:`binascii` module defines the following functions:
149
149
150
150
.. versionchanged :: 3.0
151
151
The result is always unsigned.
152
- To generate the same numeric value across all Python versions and
153
- platforms, use ``crc32(data) & 0xffffffff ``.
154
-
152
+ To generate the same numeric value when using Python 2 or earlier,
153
+ use ``crc32(data) & 0xffffffff ``.
155
154
156
155
.. function :: b2a_hex(data[, sep[, bytes_per_sep=1]])
157
156
hexlify(data[, sep[, bytes_per_sep=1]])
Original file line number Diff line number Diff line change @@ -42,10 +42,9 @@ The available exception and functions in this module are:
42
42
for use as a general hash algorithm.
43
43
44
44
.. versionchanged :: 3.0
45
- Always returns an unsigned value.
46
- To generate the same numeric value across all Python versions and
47
- platforms, use ``adler32(data) & 0xffffffff ``.
48
-
45
+ The result is always unsigned.
46
+ To generate the same numeric value when using Python 2 or earlier,
47
+ use ``adler32(data) & 0xffffffff ``.
49
48
50
49
.. function :: compress(data, /, level=-1)
51
50
@@ -127,10 +126,9 @@ The available exception and functions in this module are:
127
126
for use as a general hash algorithm.
128
127
129
128
.. versionchanged :: 3.0
130
- Always returns an unsigned value.
131
- To generate the same numeric value across all Python versions and
132
- platforms, use ``crc32(data) & 0xffffffff ``.
133
-
129
+ The result is always unsigned.
130
+ To generate the same numeric value when using Python 2 or earlier,
131
+ use ``crc32(data) & 0xffffffff ``.
134
132
135
133
.. function :: decompress(data, /, wbits=MAX_WBITS, bufsize=DEF_BUF_SIZE)
136
134
You can’t perform that action at this time.
0 commit comments