mirror of
https://github.com/python/cpython.git
synced 2025-11-02 03:01:58 +00:00
Output more details in the re tracing (GH-111357)
This commit is contained in:
parent
31c05b72c1
commit
573eff3e2e
2 changed files with 42 additions and 4 deletions
|
|
@ -107,9 +107,11 @@ static unsigned int sre_toupper(unsigned int ch) {
|
|||
|
||||
#if VERBOSE == 0
|
||||
# define INIT_TRACE(state)
|
||||
# define DO_TRACE 0
|
||||
# define TRACE(v)
|
||||
#elif VERBOSE == 1
|
||||
# define INIT_TRACE(state) int _debug = (state)->debug
|
||||
# define DO_TRACE (_debug)
|
||||
# define TRACE(v) do { \
|
||||
if (_debug) { \
|
||||
printf v; \
|
||||
|
|
@ -117,6 +119,7 @@ static unsigned int sre_toupper(unsigned int ch) {
|
|||
} while (0)
|
||||
#elif VERBOSE == 2
|
||||
# define INIT_TRACE(state)
|
||||
# define DO_TRACE 1
|
||||
# define TRACE(v) printf v
|
||||
#else
|
||||
# error VERBOSE must be 0, 1 or 2
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue