Files
RustPython/extra_tests/snippets
Hanif AriffinandJeong YunWon 8e920098b2 Fix bytes.isspace (#5655)
* Fix implementation of bytes.isspace to match the implementation in CPython.

* Fix implementation of bytes.istitle so that test_bigmem now passes.
Also added some extra_test to capture this.

* Fix some clippy issues

Signed-off-by: Hanif Ariffin <hanif.ariffin.4326@gmail.com>

* bytes.istitle returns false when the bytes is empty.

* Fix some edges of istitle with non-alphanumeric characters

* Disable a line because python 3.12 errors on bad escape sequence

* Match CPython's istitle a little closer

* Fix clippy warning

* Rewrite bytes.istitle along _Py_bytes_istitle

The lookahead-based check accepted b"Not--a Titlecase String", which
test_bytes covers. Track whether the previous byte was cased instead.

isspace compares bytes directly rather than converting to char.

Restore the b"omkmok\Xaa" assert: 3.14 reports an invalid escape
sequence as a SyntaxWarning, not an error.

Assisted-by: Claude

---------

Signed-off-by: Hanif Ariffin <hanif.ariffin.4326@gmail.com>
Co-authored-by: Jeong YunWon <jeong@youknowone.org>
2026-08-03 17:52:42 +09:00
..
2025-12-12 22:46:39 +09:00
2020-09-13 06:58:57 +09:00
2020-09-13 06:58:57 +09:00
2020-09-13 06:58:57 +09:00
2020-09-13 06:58:57 +09:00
2020-09-13 06:58:57 +09:00
2020-09-13 06:58:57 +09:00
2025-11-15 23:09:31 +09:00
2025-12-12 22:46:39 +09:00
2025-12-12 22:46:39 +09:00
2026-01-17 19:21:10 +09:00
2026-08-03 17:52:42 +09:00
2025-06-22 00:00:07 +09:00
2025-07-07 19:02:37 +09:00
2026-01-17 19:21:11 +09:00
2020-09-13 06:58:57 +09:00
2026-08-02 21:21:11 +09:00
2026-01-29 16:48:02 +09:00
2025-12-12 22:46:39 +09:00
2020-09-13 06:58:57 +09:00
2026-01-17 19:21:11 +09:00
2026-01-17 19:21:11 +09:00
2020-09-13 06:58:57 +09:00
2025-12-12 22:46:39 +09:00
2020-09-13 06:58:57 +09:00
2025-05-12 14:20:01 +09:00
2025-05-12 14:20:01 +09:00
2025-12-12 22:46:39 +09:00
2026-02-08 13:58:30 +00:00
2022-10-17 13:45:15 +09:00
2023-05-23 16:43:52 +09:00
2025-12-12 22:46:39 +09:00
2025-12-12 22:46:39 +09:00
2025-12-12 22:46:39 +09:00
2025-12-12 22:46:39 +09:00
2025-12-12 22:46:39 +09:00
2025-12-12 22:46:39 +09:00
2020-09-13 06:58:57 +09:00
2025-12-12 22:46:39 +09:00
2025-12-12 22:46:39 +09:00
2026-01-17 19:21:11 +09:00
2025-12-12 22:46:39 +09:00
2025-12-12 22:46:39 +09:00
2025-12-12 22:46:39 +09:00
2026-07-07 09:19:25 +09:00
2025-12-12 22:46:39 +09:00
2023-05-19 14:05:36 -04:00
2025-02-13 14:11:01 +09:00
2023-02-13 21:28:19 +09:00
2022-05-04 02:54:59 +09:00
2025-08-26 21:48:46 +09:00
2020-09-13 06:58:57 +09:00