summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1996-12-30 16:17:54 (GMT)
committerGuido van Rossum <guido@python.org>1996-12-30 16:17:54 (GMT)
commit408027ea4635de5c892b28c4fdf41840eb9089a4 (patch)
tree26a28bfbfa94697565ce4440da84772e2bb96acb /Python
parenta0dc1c4a613f11e1b6e20fa25658823533ca201b (diff)
downloadcpython-408027ea4635de5c892b28c4fdf41840eb9089a4.zip
cpython-408027ea4635de5c892b28c4fdf41840eb9089a4.tar.gz
cpython-408027ea4635de5c892b28c4fdf41840eb9089a4.tar.bz2
Rename DEBUG macro to Py_DEBUG
Diffstat (limited to 'Python')
-rw-r--r--Python/ceval.c6
-rw-r--r--Python/thread.c6
-rw-r--r--Python/thread_sgi.h6
3 files changed, 9 insertions, 9 deletions
diff --git a/Python/ceval.c b/Python/ceval.c
index 7b7fdf0..816973f 100644
--- a/Python/ceval.c
+++ b/Python/ceval.c
@@ -51,7 +51,7 @@ PERFORMANCE OF THIS SOFTWARE.
/* Turn this on if your compiler chokes on the big switch: */
/* #define CASE_TOO_BIG 1 */
-#ifdef DEBUG
+#ifdef Py_DEBUG
/* For debugging the interpreter: */
#define LLTRACE 1 /* Low-level trace feature */
#define CHECKEXC 1 /* Double-check exception checking */
@@ -339,7 +339,7 @@ eval_code2(co, globals, locals,
#ifdef LLTRACE
int lltrace;
#endif
-#if defined(DEBUG) || defined(LLTRACE)
+#if defined(Py_DEBUG) || defined(LLTRACE)
/* Make it easier to find out where we are with a debugger */
char *filename = getstringvalue(co->co_filename);
#endif
@@ -602,7 +602,7 @@ eval_code2(co, globals, locals,
/* Extract opcode and argument */
-#if defined(DEBUG) || defined(LLTRACE)
+#if defined(Py_DEBUG) || defined(LLTRACE)
f->f_lasti = INSTR_OFFSET();
#endif
diff --git a/Python/thread.c b/Python/thread.c
index 0e6d6ee..ad7dd5c 100644
--- a/Python/thread.c
+++ b/Python/thread.c
@@ -83,7 +83,7 @@ extern char *getenv();
#define _P2(v1,t1,v2,t2) (v1,v2) t1; t2;
#endif /* __STDC__ */
-#ifdef DEBUG
+#ifdef Py_DEBUG
static int thread_debug = 0;
#define dprintf(args) ((thread_debug & 1) && printf args)
#define d2printf(args) ((thread_debug & 8) && printf args)
@@ -98,7 +98,7 @@ static void _init_thread(); /* Forward */
void init_thread _P0()
{
-#ifdef DEBUG
+#ifdef Py_DEBUG
char *p = getenv("THREADDEBUG");
if (p) {
@@ -107,7 +107,7 @@ void init_thread _P0()
else
thread_debug = 1;
}
-#endif /* DEBUG */
+#endif /* Py_DEBUG */
if (initialized)
return;
initialized = 1;
diff --git a/Python/thread_sgi.h b/Python/thread_sgi.h
index 2774e49..32b94f2 100644
--- a/Python/thread_sgi.h
+++ b/Python/thread_sgi.h
@@ -77,7 +77,7 @@ static void exit_sig _P0()
}
if (do_exit) {
d2printf(("exiting in exit_sig\n"));
-#ifdef DEBUG
+#ifdef Py_DEBUG
if ((thread_debug & 8) == 0)
thread_debug &= ~1; /* don't produce debug messages */
#endif
@@ -140,12 +140,12 @@ static void _init_thread _P0()
if (usconfig(CONF_ARENATYPE, US_SHAREDONLY) < 0)
perror("usconfig - CONF_ARENATYPE");
usconfig(CONF_LOCKTYPE, US_DEBUG); /* XXX */
-#ifdef DEBUG
+#ifdef Py_DEBUG
if (thread_debug & 4)
usconfig(CONF_LOCKTYPE, US_DEBUGPLUS);
else if (thread_debug & 2)
usconfig(CONF_LOCKTYPE, US_DEBUG);
-#endif /* DEBUG */
+#endif /* Py_DEBUG */
if ((shared_arena = usinit(tmpnam(0))) == 0)
perror("usinit");
#ifdef USE_DL