From: Barney Gale Date: Tue, 16 Jan 2024 01:37:55 +0000 (+0000) Subject: [3.11] GH-101130: Document multiple arguments for `PurePath.[is_]relative_to()` ... X-Git-Tag: v3.11.8~154 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f5cbed1114cae19744a9f9a460154322688b6318;p=thirdparty%2FPython%2Fcpython.git [3.11] GH-101130: Document multiple arguments for `PurePath.[is_]relative_to()` (#114034) 3.11-only change as this is already covered in the 3.12+ deprecation warning. --- diff --git a/Doc/library/pathlib.rst b/Doc/library/pathlib.rst index 974ab424a57f..2d35285c12bd 100644 --- a/Doc/library/pathlib.rst +++ b/Doc/library/pathlib.rst @@ -508,6 +508,8 @@ Pure paths provide the following methods and properties: >>> p.is_relative_to('/usr') False + If multiple arguments are supplied, they are joined together. + .. versionadded:: 3.9 @@ -589,6 +591,8 @@ Pure paths provide the following methods and properties: .format(str(self), str(formatted))) ValueError: '/etc/passwd' is not in the subpath of '/usr' OR one path is relative and the other absolute. + If multiple arguments are supplied, they are joined together. + NOTE: This function is part of :class:`PurePath` and works with strings. It does not check or access the underlying file structure.