diff options
author | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2016-07-25 14:43:04 +0300 |
---|---|---|
committer | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2016-07-25 14:45:08 +0300 |
commit | 6af90b29725a85f275380d1973b1454e25e6bdbc (patch) | |
tree | 90a2693cf3e4ab73af68c9f8963521a5ef7f50c7 /tests/basics/bytes_find.py | |
parent | 16f324641f33201061fb4e79677bc760e45fb3ac (diff) |
py/objstrunicode: str_index_to_ptr: Should handle bytes too.
There's single str_index_to_ptr() function, called for both bytes and
unicode objects, so should handle each properly.
Diffstat (limited to 'tests/basics/bytes_find.py')
-rw-r--r-- | tests/basics/bytes_find.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/basics/bytes_find.py b/tests/basics/bytes_find.py index 434669a90..75ef9796c 100644 --- a/tests/basics/bytes_find.py +++ b/tests/basics/bytes_find.py @@ -21,3 +21,6 @@ print(b"0000".find(b'-1', 3)) print(b"0000".find(b'1', 3)) print(b"0000".find(b'1', 4)) print(b"0000".find(b'1', 5)) + +# Non-ascii values (make sure not treated as unicode-like) +print(b"\x80abc".find(b"a", 1)) |