mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
Rename buffer -> bytearray.
This commit is contained in:
parent
905a904723
commit
254348e201
31 changed files with 290 additions and 290 deletions
|
@ -163,7 +163,7 @@ class _Database(UserDict.DictMixin):
|
|||
if not isinstance(key, bytes):
|
||||
raise TypeError("keys must be bytes")
|
||||
key = key.decode("latin-1") # hashable bytes
|
||||
if not isinstance(val, (buffer, bytes)):
|
||||
if not isinstance(val, (bytes, bytearray)):
|
||||
raise TypeError("values must be byte strings")
|
||||
if key not in self._index:
|
||||
self._addkey(key, self._addval(val))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue