diff options
author | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2015-11-21 16:34:57 +0200 |
---|---|---|
committer | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2015-11-21 16:54:15 +0200 |
commit | 295ea12411ca12a41947de3113febb29e469ac4c (patch) | |
tree | 7d2ee9ba2e7b2ccdeb07d2865fa6413f1c388a2b | |
parent | 72bd172b305fc7e3c8d3a111e0453f4420d1a10b (diff) | |
download | micropython-295ea12411ca12a41947de3113febb29e469ac4c.tar.gz micropython-295ea12411ca12a41947de3113febb29e469ac4c.zip |
py/emitglue: Host definition of mp_verbose_flag.
This may not seem like the ideal place, but is actually the only place
in py/ where it gets referenced, so is just right.
-rw-r--r-- | lib/utils/printf.c | 2 | ||||
-rw-r--r-- | py/emitglue.c | 4 | ||||
-rw-r--r-- | unix/main.c | 1 |
3 files changed, 4 insertions, 3 deletions
diff --git a/lib/utils/printf.c b/lib/utils/printf.c index 611ad2df4c..082b1c65a8 100644 --- a/lib/utils/printf.c +++ b/lib/utils/printf.c @@ -48,8 +48,6 @@ int vprintf(const char *fmt, va_list ap) { } #if MICROPY_DEBUG_PRINTERS -mp_uint_t mp_verbose_flag = 1; - int DEBUG_printf(const char *fmt, ...) { va_list ap; va_start(ap, fmt); diff --git a/py/emitglue.c b/py/emitglue.c index a0f0e004eb..e6f3fc16d8 100644 --- a/py/emitglue.c +++ b/py/emitglue.c @@ -45,6 +45,10 @@ #define DEBUG_OP_printf(...) (void)0 #endif +#if MICROPY_DEBUG_PRINTERS +mp_uint_t mp_verbose_flag = 0; +#endif + struct _mp_raw_code_t { mp_raw_code_kind_t kind : 3; mp_uint_t scope_flags : 7; diff --git a/unix/main.c b/unix/main.c index 26b7a13683..26618af3f7 100644 --- a/unix/main.c +++ b/unix/main.c @@ -51,7 +51,6 @@ // Command line options, with their defaults STATIC bool compile_only = false; STATIC uint emit_opt = MP_EMIT_OPT_NONE; -mp_uint_t mp_verbose_flag = 0; #if MICROPY_ENABLE_GC // Heap size of GC heap (if enabled) |