summaryrefslogtreecommitdiffstats
path: root/Doc/library/dbm.rst
diff options
context:
space:
mode:
authorErlend E. Aasland <erlend@python.org>2024-01-26 12:36:37 (GMT)
committerGitHub <noreply@github.com>2024-01-26 12:36:37 (GMT)
commit8710faeac28e65c65862359413e8341492f529af (patch)
treed5877f0a3c12e68b6536ca53b4010ead2102b43f /Doc/library/dbm.rst
parent4cf068ed0879cccf86a45f06fb274b350b89e911 (diff)
downloadcpython-8710faeac28e65c65862359413e8341492f529af.zip
cpython-8710faeac28e65c65862359413e8341492f529af.tar.gz
cpython-8710faeac28e65c65862359413e8341492f529af.tar.bz2
Docs: fix versionchanged directives for dbm.open() and dbm.whichdb() (#114594)
Diffstat (limited to 'Doc/library/dbm.rst')
-rw-r--r--Doc/library/dbm.rst10
1 files changed, 5 insertions, 5 deletions
diff --git a/Doc/library/dbm.rst b/Doc/library/dbm.rst
index bc5bb0c..55846e9 100644
--- a/Doc/library/dbm.rst
+++ b/Doc/library/dbm.rst
@@ -34,8 +34,8 @@ the Oracle Berkeley DB.
* the empty string (``''``) if the file's format can't be guessed
* a string containing the required module name, such as ``'dbm.ndbm'`` or ``'dbm.gnu'``
-.. versionchanged:: 3.11
- Accepts :term:`path-like object` for filename.
+ .. versionchanged:: 3.11
+ *filename* accepts a :term:`path-like object`.
.. Substitutions for the open() flag param docs;
all submodules use the same text.
@@ -78,6 +78,9 @@ the Oracle Berkeley DB.
database has to be created. It defaults to octal ``0o666`` (and will be
modified by the prevailing umask).
+ .. versionchanged:: 3.11
+ *file* accepts a :term:`path-like object`.
+
The object returned by :func:`open` supports the same basic functionality as a
:class:`dict`; keys and their corresponding values can be stored, retrieved, and
@@ -91,9 +94,6 @@ available, as well as :meth:`!get` and :meth:`!setdefault`.
Deleting a key from a read-only database raises database module specific error
instead of :exc:`KeyError`.
-.. versionchanged:: 3.11
- Accepts :term:`path-like object` for file.
-
Key and values are always stored as :class:`bytes`. This means that when
strings are used they are implicitly converted to the default encoding before
being stored.