summaryrefslogtreecommitdiff
path: root/Modules/sre_lib.h
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2015-11-05 17:43:42 +0200
committerSerhiy Storchaka <storchaka@gmail.com>2015-11-05 17:43:42 +0200
commit12b2538ab8e44d69d9ed2c8b329812130db9e6bc (patch)
treebaa5d5fe21646635f4fa6f49fe98a69be17fca07 /Modules/sre_lib.h
parente20310fa19188f764b84fbdc40d32d6933f98af9 (diff)
downloadcpython-git-12b2538ab8e44d69d9ed2c8b329812130db9e6bc.tar.gz
Reuse Py_STRINGIFY() macro in sre_lib.h and dynload_win.c.
Diffstat (limited to 'Modules/sre_lib.h')
-rw-r--r--Modules/sre_lib.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/Modules/sre_lib.h b/Modules/sre_lib.h
index 6ad2ab72e3..78f7ac745e 100644
--- a/Modules/sre_lib.h
+++ b/Modules/sre_lib.h
@@ -367,14 +367,12 @@ SRE(info)(SRE_STATE* state, SRE_CODE* pattern)
#define RETURN_ON_FAILURE(i) \
do { RETURN_ON_ERROR(i); if (i == 0) RETURN_FAILURE; } while (0)
-#define SFY(x) #x
-
#define DATA_STACK_ALLOC(state, type, ptr) \
do { \
alloc_pos = state->data_stack_base; \
TRACE(("allocating %s in %" PY_FORMAT_SIZE_T "d " \
"(%" PY_FORMAT_SIZE_T "d)\n", \
- SFY(type), alloc_pos, sizeof(type))); \
+ Py_STRINGIFY(type), alloc_pos, sizeof(type))); \
if (sizeof(type) > state->data_stack_size - alloc_pos) { \
int j = data_stack_grow(state, sizeof(type)); \
if (j < 0) return j; \
@@ -387,7 +385,7 @@ do { \
#define DATA_STACK_LOOKUP_AT(state, type, ptr, pos) \
do { \
- TRACE(("looking up %s at %" PY_FORMAT_SIZE_T "d\n", SFY(type), pos)); \
+ TRACE(("looking up %s at %" PY_FORMAT_SIZE_T "d\n", Py_STRINGIFY(type), pos)); \
ptr = (type*)(state->data_stack+pos); \
} while (0)