mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
Fix 're' to work on bytes. It could do with a few more tests, though.
This commit is contained in:
parent
e8c3d266c8
commit
40a088dc27
3 changed files with 22 additions and 34 deletions
|
@ -472,7 +472,7 @@ def _compile_info(code, pattern, flags):
|
|||
code[skip] = len(code) - skip
|
||||
|
||||
def isstring(obj):
|
||||
return isinstance(obj, str)
|
||||
return isinstance(obj, (str, bytes))
|
||||
|
||||
def _code(p, flags):
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue