bpo-20216: Correct docstrings of digest() methods in hashlib. (GH-9873) · python/cpython@f192aeb (original) (raw)
Navigation Menu
- Explore
- Pricing
Provide feedback
Saved searches
Use saved searches to filter your results more quickly
Appearance settings
Commit f192aeb
authored and
committed
File tree
9 files changed
lines changed
9 files changed
lines changed
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -187,7 +187,7 @@ EVP_copy(EVPobject *self, PyObject *unused) | ||
187 | 187 | } |
188 | 188 | |
189 | 189 | PyDoc_STRVAR(EVP_digest__doc__, |
190 | -"Return the digest value as a string of binary data."); | |
190 | +"Return the digest value as a bytes object."); | |
191 | 191 | |
192 | 192 | static PyObject * |
193 | 193 | EVP_digest(EVPobject *self, PyObject *unused) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -361,12 +361,12 @@ MD5Type_copy_impl(MD5object *self) | ||
361 | 361 | /*[clinic input] |
362 | 362 | MD5Type.digest |
363 | 363 | |
364 | -Return the digest value as a string of binary data. | |
364 | +Return the digest value as a bytes object. | |
365 | 365 | [clinic start generated code]*/ |
366 | 366 | |
367 | 367 | static PyObject * |
368 | 368 | MD5Type_digest_impl(MD5object *self) |
369 | -/*[clinic end generated code: output=eb691dc4190a07ec input=7b96e65389412a34]*/ | |
369 | +/*[clinic end generated code: output=eb691dc4190a07ec input=bc0c4397c2994be6]*/ | |
370 | 370 | { |
371 | 371 | unsigned char digest[MD5_DIGESTSIZE]; |
372 | 372 | struct md5_state temp; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -338,12 +338,12 @@ SHA1Type_copy_impl(SHA1object *self) | ||
338 | 338 | /*[clinic input] |
339 | 339 | SHA1Type.digest |
340 | 340 | |
341 | -Return the digest value as a string of binary data. | |
341 | +Return the digest value as a bytes object. | |
342 | 342 | [clinic start generated code]*/ |
343 | 343 | |
344 | 344 | static PyObject * |
345 | 345 | SHA1Type_digest_impl(SHA1object *self) |
346 | -/*[clinic end generated code: output=2f05302a7aa2b5cb input=205d47e1927fd009]*/ | |
346 | +/*[clinic end generated code: output=2f05302a7aa2b5cb input=13824b35407444bd]*/ | |
347 | 347 | { |
348 | 348 | unsigned char digest[SHA1_DIGESTSIZE]; |
349 | 349 | struct sha1_state temp; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -428,12 +428,12 @@ SHA256Type_copy_impl(SHAobject *self) | ||
428 | 428 | /*[clinic input] |
429 | 429 | SHA256Type.digest |
430 | 430 | |
431 | -Return the digest value as a string of binary data. | |
431 | +Return the digest value as a bytes object. | |
432 | 432 | [clinic start generated code]*/ |
433 | 433 | |
434 | 434 | static PyObject * |
435 | 435 | SHA256Type_digest_impl(SHAobject *self) |
436 | -/*[clinic end generated code: output=46616a5e909fbc3d input=1fb752e58954157d]*/ | |
436 | +/*[clinic end generated code: output=46616a5e909fbc3d input=f1f4cfea5cbde35c]*/ | |
437 | 437 | { |
438 | 438 | unsigned char digest[SHA_DIGESTSIZE]; |
439 | 439 | SHAobject temp; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -493,12 +493,12 @@ SHA512Type_copy_impl(SHAobject *self) | ||
493 | 493 | /*[clinic input] |
494 | 494 | SHA512Type.digest |
495 | 495 | |
496 | -Return the digest value as a string of binary data. | |
496 | +Return the digest value as a bytes object. | |
497 | 497 | [clinic start generated code]*/ |
498 | 498 | |
499 | 499 | static PyObject * |
500 | 500 | SHA512Type_digest_impl(SHAobject *self) |
501 | -/*[clinic end generated code: output=1080bbeeef7dde1b input=60c2cede9e023018]*/ | |
501 | +/*[clinic end generated code: output=1080bbeeef7dde1b input=f6470dd359071f4b]*/ | |
502 | 502 | { |
503 | 503 | unsigned char digest[SHA_DIGESTSIZE]; |
504 | 504 | SHAobject temp; |