mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
Issue 28128: Print out better error/warning messages for invalid string escapes.
This commit is contained in:
parent
a99cdb21a7
commit
42454af094
8 changed files with 173 additions and 22 deletions
|
@ -74,6 +74,11 @@ PyAPI_FUNC(PyObject*) _PyBytes_FromHex(
|
|||
PyAPI_FUNC(PyObject *) PyBytes_DecodeEscape(const char *, Py_ssize_t,
|
||||
const char *, Py_ssize_t,
|
||||
const char *);
|
||||
/* Helper for PyBytes_DecodeEscape that detects invalid escape chars. */
|
||||
PyAPI_FUNC(PyObject *) _PyBytes_DecodeEscape(const char *, Py_ssize_t,
|
||||
const char *, Py_ssize_t,
|
||||
const char *,
|
||||
const char **);
|
||||
|
||||
/* Macro, trading safety for speed */
|
||||
#ifndef Py_LIMITED_API
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue