[doc] Fix erroneous backslashes in signatures and names (GH-23658)
The issue being resolved is shown in the 3.10 docs (if you select docs for older versions you won't see a visual glitch).
The newer sphinx version that produces the 3.10 docs doesn't treat the backslash to escape things in some situations it previously did.
diff --git a/Doc/library/os.rst b/Doc/library/os.rst
index b309988..ab1a615 100644
--- a/Doc/library/os.rst
+++ b/Doc/library/os.rst
@@ -1991,7 +1991,7 @@
Accepts a :term:`path-like object`.
-.. function:: lstat(path, \*, dir_fd=None)
+.. function:: lstat(path, *, dir_fd=None)
Perform the equivalent of an :c:func:`lstat` system call on the given path.
Similar to :func:`~os.stat`, but does not follow symbolic links. Return a
@@ -2498,7 +2498,7 @@
On the first, uncached call, a system call is required on Windows but
not on Unix.
- .. method:: is_dir(\*, follow_symlinks=True)
+ .. method:: is_dir(*, follow_symlinks=True)
Return ``True`` if this entry is a directory or a symbolic link pointing
to a directory; return ``False`` if the entry is or points to any other
@@ -2522,7 +2522,7 @@
This method can raise :exc:`OSError`, such as :exc:`PermissionError`,
but :exc:`FileNotFoundError` is caught and not raised.
- .. method:: is_file(\*, follow_symlinks=True)
+ .. method:: is_file(*, follow_symlinks=True)
Return ``True`` if this entry is a file or a symbolic link pointing to a
file; return ``False`` if the entry is or points to a directory or other
@@ -2552,7 +2552,7 @@
This method can raise :exc:`OSError`, such as :exc:`PermissionError`,
but :exc:`FileNotFoundError` is caught and not raised.
- .. method:: stat(\*, follow_symlinks=True)
+ .. method:: stat(*, follow_symlinks=True)
Return a :class:`stat_result` object for this entry. This method
follows symbolic links by default; to stat a symbolic link add the
@@ -2584,7 +2584,7 @@
for :class:`bytes` paths on Windows.
-.. function:: stat(path, \*, dir_fd=None, follow_symlinks=True)
+.. function:: stat(path, *, dir_fd=None, follow_symlinks=True)
Get the status of a file or a file descriptor. Perform the equivalent of a
:c:func:`stat` system call on the given path. *path* may be specified as