File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4444#if 0 // print debugging info
4545#define DEBUG_PRINT (1)
4646#else // don't print debugging info
47+ #define DEBUG_PRINT (0)
4748#define DEBUG_printf (...) (void)0
4849#endif
4950
Original file line number Diff line number Diff line change 5050#define DEBUG_PRINT (1)
5151#define DEBUG_printf DEBUG_printf
5252#else // don't print debugging info
53+ #define DEBUG_PRINT (0)
5354#define DEBUG_printf (...) (void)0
5455#endif
5556
Original file line number Diff line number Diff line change 4444#define DEBUG_PRINT (1)
4545#define DEBUG_printf DEBUG_printf
4646#else // don't print debugging info
47+ #define DEBUG_PRINT (0)
4748#define DEBUG_printf (...) (void)0
4849#endif
4950
@@ -746,7 +747,9 @@ void gc_dump_alloc_table(void) {
746747 if (* ptr == (mp_uint_t )& mp_type_tuple ) { c = 'T' ; }
747748 else if (* ptr == (mp_uint_t )& mp_type_list ) { c = 'L' ; }
748749 else if (* ptr == (mp_uint_t )& mp_type_dict ) { c = 'D' ; }
750+ #if MICROPY_PY_BUILTINS_FLOAT
749751 else if (* ptr == (mp_uint_t )& mp_type_float ) { c = 'F' ; }
752+ #endif
750753 else if (* ptr == (mp_uint_t )& mp_type_fun_bc ) { c = 'B' ; }
751754 else if (* ptr == (mp_uint_t )& mp_type_module ) { c = 'M' ; }
752755 else { c = 'h' ; }
Original file line number Diff line number Diff line change @@ -358,7 +358,7 @@ void mp_set_clear(mp_set_t *set) {
358358 set -> table = NULL ;
359359}
360360
361- #if DEBUG_PRINT
361+ #if defined( DEBUG_PRINT ) && DEBUG_PRINT
362362void mp_map_dump (mp_map_t * map ) {
363363 for (mp_uint_t i = 0 ; i < map -> alloc ; i ++ ) {
364364 if (map -> table [i ].key != NULL ) {
Original file line number Diff line number Diff line change 184184#endif
185185
186186// Whether to enable finalisers in the garbage collector (ie call __del__)
187- #ifndef MICROPY_ENABLE_GC_FINALISER
188- #define MICROPY_ENABLE_GC_FINALISER (0)
187+ #ifndef MICROPY_ENABLE_FINALISER
188+ #define MICROPY_ENABLE_FINALISER (0)
189189#endif
190190
191191// Whether to check C stack usage. C stack used for calling Python functions,
Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ struct _nlr_buf_t {
3636 // the entries here must all be machine word size
3737 nlr_buf_t * prev ;
3838 void * ret_val ;
39- #if !MICROPY_NLR_SETJMP
39+ #if !defined( MICROPY_NLR_SETJMP ) || ! MICROPY_NLR_SETJMP
4040#if defined(__i386__ )
4141 void * regs [6 ];
4242#elif defined(__x86_64__ )
Original file line number Diff line number Diff line change 2424 * THE SOFTWARE.
2525 */
2626
27- #if ! MICROPY_NLR_SETJMP && (defined(__thumb2__) || defined(__thumb__) || defined(__arm__))
27+ #if (!defined( MICROPY_NLR_SETJMP) || !MICROPY_NLR_SETJMP) && (defined(__thumb2__) || defined(__thumb__) || defined(__arm__))
2828
2929// We only need the functions here if we are on arm/thumb, and we are not
3030// using setjmp/longjmp.
@@ -138,4 +138,4 @@ nlr_jump:
138138nlr_top:
139139 .space 4
140140
141- #endif // ! MICROPY_NLR_SETJMP && (defined(__thumb2__) || defined(__thumb__) || defined(__arm__))
141+ #endif // (!defined( MICROPY_NLR_SETJMP) || !MICROPY_NLR_SETJMP) && (defined(__thumb2__) || defined(__thumb__) || defined(__arm__))
Original file line number Diff line number Diff line change 4444#if 0 // print debugging info
4545#define DEBUG_PRINT (1)
4646#else // don't print debugging info
47+ #define DEBUG_PRINT (0)
4748#define DEBUG_printf (...) (void)0
4849#endif
4950
Original file line number Diff line number Diff line change 4343#define DEBUG_PRINT (1)
4444#define DEBUG_printf DEBUG_printf
4545#else // don't print debugging info
46+ #define DEBUG_PRINT (0)
4647#define DEBUG_printf (...) (void)0
4748#endif
4849
Original file line number Diff line number Diff line change 2929#include <stdarg.h>
3030
3131#include "mpconfig.h"
32- #include "std.h"
3332#include "misc.h"
34- #include "systick.h"
3533#include "qstr.h"
3634#include "obj.h"
3735#include "pfenv.h"
38- #if 0
39- #include "lcd.h"
40- #endif
41- #include "uart.h"
42- #include "usb.h"
4336#include "pybstdio.h"
4437
4538#if MICROPY_PY_BUILTINS_FLOAT
You can’t perform that action at this time.
0 commit comments