From 34b4b5e2e986620c47ae0f81476accac634b28b3 Mon Sep 17 00:00:00 2001 From: Yongzi Li <204532581+Yzi-Li@users.noreply.github.com> Date: Sun, 13 Jul 2025 13:56:31 +0800 Subject: [PATCH] gh-134833: improve docs for `del s[i:j]` in `Mutable Sequence Types` (GH-134834) (cherry picked from commit 609d5adc7cc241da8fe314a64ddd2c8a883ee8b7) Co-authored-by: Yongzi Li <204532581+Yzi-Li@users.noreply.github.com> --- Doc/library/stdtypes.rst | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Doc/library/stdtypes.rst b/Doc/library/stdtypes.rst index 87855970b64979..63b251c6268e66 100644 --- a/Doc/library/stdtypes.rst +++ b/Doc/library/stdtypes.rst @@ -1181,7 +1181,9 @@ accepts integers that meet the value restriction ``0 <= x <= 255``). | | is replaced by the contents of | | | | the iterable *t* | | +------------------------------+--------------------------------+---------------------+ -| ``del s[i:j]`` | same as ``s[i:j] = []`` | | +| ``del s[i:j]`` | removes the elements of | | +| | ``s[i:j]`` from the list | | +| | (same as ``s[i:j] = []``) | | +------------------------------+--------------------------------+---------------------+ | ``s[i:j:k] = t`` | the elements of ``s[i:j:k]`` | \(1) | | | are replaced by those of *t* | |