Skip to content

Commit 576783d

Browse files
committed
Add platform examples per review feedback
1 parent d067871 commit 576783d

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Doc/library/os.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2732,8 +2732,9 @@ features:
27322732
.. function:: remove(path, *, dir_fd=None)
27332733

27342734
Remove (delete) the file *path*. If *path* is a directory, an
2735-
:exc:`OSError` is raised. The exact exception type depends on the platform:
2736-
for example, :exc:`IsADirectoryError` or :exc:`PermissionError`.
2735+
:exc:`OSError` is raised. The exact subclass depends on the platform:
2736+
for example, :exc:`IsADirectoryError` on Linux or :exc:`PermissionError`
2737+
on macOS.
27372738
Use :func:`rmdir` to remove directories.
27382739
If the file does not exist, a :exc:`FileNotFoundError` is raised.
27392740

0 commit comments

Comments
 (0)