Skip to content

Commit b8624c6

Browse files
authored
Merge pull request #3454 from YYun-D/doc_modify
Fix `bytearray` and `bytes` docs
2 parents 7305be8 + 7de142f commit b8624c6

File tree

3 files changed

+0
-22
lines changed

3 files changed

+0
-22
lines changed

Lib/test/test_bytes.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1753,8 +1753,6 @@ def test_compare_bytes_to_bytearray(self):
17531753
self.assertEqual(bytes(b"abc") < b"ab", False)
17541754
self.assertEqual(bytes(b"abc") <= b"ab", False)
17551755

1756-
# TODO: RUSTPYTHON
1757-
@unittest.expectedFailure
17581756
@test.support.requires_docstrings
17591757
def test_doc(self):
17601758
self.assertIsNotNone(bytearray.__doc__)

vm/src/builtins/bytearray.rs

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -35,17 +35,6 @@ use crate::{
3535
use bstr::ByteSlice;
3636
use std::mem::size_of;
3737

38-
/// "bytearray(iterable_of_ints) -> bytearray\n\
39-
/// bytearray(string, encoding[, errors]) -> bytearray\n\
40-
/// bytearray(bytes_or_buffer) -> mutable copy of bytes_or_buffer\n\
41-
/// bytearray(int) -> bytes array of size given by the parameter initialized with null bytes\n\
42-
/// bytearray() -> empty bytes array\n\n\
43-
/// Construct a mutable bytearray object from:\n \
44-
/// - an iterable yielding integers in range(256)\n \
45-
/// - a text string encoded using the specified encoding\n \
46-
/// - a bytes or a buffer object\n \
47-
/// - any object implementing the buffer API.\n \
48-
/// - an integer";
4938
#[pyclass(module = false, name = "bytearray")]
5039
#[derive(Debug, Default)]
5140
pub struct PyByteArray {

vm/src/builtins/bytes.rs

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,6 @@ use bstr::ByteSlice;
2323
use std::mem::size_of;
2424
use std::ops::Deref;
2525

26-
/// "bytes(iterable_of_ints) -> bytes\n\
27-
/// bytes(string, encoding[, errors]) -> bytes\n\
28-
/// bytes(bytes_or_buffer) -> immutable copy of bytes_or_buffer\n\
29-
/// bytes(int) -> bytes object of size given by the parameter initialized with null bytes\n\
30-
/// bytes() -> empty bytes object\n\nConstruct an immutable array of bytes from:\n \
31-
/// - an iterable yielding integers in range(256)\n \
32-
/// - a text string encoded using the specified encoding\n \
33-
/// - any object implementing the buffer API.\n \
34-
/// - an integer";
3526
#[pyclass(module = false, name = "bytes")]
3627
#[derive(Clone, Debug)]
3728
pub struct PyBytes {

0 commit comments

Comments
 (0)