* 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>
This directory contains all of the Python files that make up the standard
library for RustPython.
Most of these files are copied over from the CPython repository (the 3.7
branch), with slight modifications to allow them to work under RustPython. The
current goal is to complete the standard library with as few modifications as
possible. Current modifications are just temporary workarounds for bugs/missing
feature within the RustPython implementation.
The first big module we are targeting is unittest, so we can leverage the
CPython test suite.