Skip to content

Commit 19777d6

Browse files
committed
Adjust docstring examples
1 parent b0aa73e commit 19777d6

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

Doc/library/os.path.rst

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -502,21 +502,21 @@ the :mod:`glob` module.)
502502
<https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap04.html#tag_04_13>`_.)
503503
For example::
504504

505-
>>> splitroot('/etc/hosts')
506-
('', '/', 'etc/hosts')
505+
>>> splitroot('/home/eryk')
506+
('', '/', 'home/eryk')
507+
>>> splitroot('//home/eryk')
508+
('', '//', 'home/eryk')
509+
>>> splitroot('///home/eryk')
510+
('', '/', '//home/eryk')
507511

508512
On Windows, *drive* may be empty, a drive-letter name, a UNC share, or a device
509513
name. The *root* may be empty, a forward slash, or a backward slash. For
510514
example::
511515

512-
>>> splitroot('Windows/notepad')
513-
('', '', 'Windows/notepad')
514-
>>> splitroot('C:/Users/Barney')
515-
('C:', '/', 'Users/Barney')
516-
>>> splitroot('//server/share/')
517-
('//server/share', '/', '')
518-
>>> splitroot('//?/UNC/server/share/')
519-
('//?/UNC/server/share', '/', '')
516+
>>> splitroot('C:/Users/Eryk')
517+
('C:', '/', 'Users/Eryk')
518+
>>> splitroot('//Server/Share/Users/Eryk')
519+
('//Server/Share', '/', 'Users/Eryk')
520520

521521
In all cases, ``drive + root + tail`` will be the same as *path*.
522522

0 commit comments

Comments
 (0)