From e1aa55818856d5f269b4feddf542917a8f5dd5f3 Mon Sep 17 00:00:00 2001 From: Jelle Zijlstra Date: Tue, 15 May 2018 11:20:48 -0400 Subject: [PATCH] add bytearray.copy to Python 3 Fixes #1715. 2.7's bytearray doesn't have it. --- stdlib/3/builtins.pyi | 1 + 1 file changed, 1 insertion(+) diff --git a/stdlib/3/builtins.pyi b/stdlib/3/builtins.pyi index 8bdeff309fb1..51337b9679bd 100644 --- a/stdlib/3/builtins.pyi +++ b/stdlib/3/builtins.pyi @@ -429,6 +429,7 @@ class bytearray(MutableSequence[int], ByteString): def count(self, sub: Union[bytes, int], start: Optional[int] = ..., end: Optional[int] = ...) -> int: ... else: def count(self, sub: bytes, start: Optional[int] = ..., end: Optional[int] = ...) -> int: ... + def copy(self) -> bytearray: ... def decode(self, encoding: str = ..., errors: str = ...) -> str: ... def endswith(self, suffix: bytes) -> bool: ... def expandtabs(self, tabsize: int = ...) -> bytearray: ...