Skip to content

Commit b5190f1

Browse files
committed
unix/mpconfigport_minimal.h: Clearly mark where user-define config ends.
TODO: Do the same for other config files.
1 parent 230d5cd commit b5190f1

1 file changed

Lines changed: 13 additions & 10 deletions

File tree

unix/mpconfigport_minimal.h

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
#define MICROPY_ENABLE_SOURCE_LINE (0)
3939
#define MICROPY_ERROR_REPORTING (MICROPY_ERROR_REPORTING_TERSE)
4040
#define MICROPY_WARNINGS (0)
41+
#define MICROPY_ENABLE_EMERGENCY_EXCEPTION_BUF (0)
4142
#define MICROPY_FLOAT_IMPL (MICROPY_FLOAT_IMPL_NONE)
4243
#define MICROPY_LONGINT_IMPL (MICROPY_LONGINT_IMPL_NONE)
4344
#define MICROPY_STREAMS_NON_BLOCK (0)
@@ -83,6 +84,18 @@
8384
#define MICROPY_PY_UHASHLIB (0)
8485
#define MICROPY_PY_UBINASCII (0)
8586

87+
extern const struct _mp_obj_module_t mp_module_os;
88+
89+
#define MICROPY_PORT_BUILTIN_MODULES \
90+
{ MP_OBJ_NEW_QSTR(MP_QSTR_uos), (mp_obj_t)&mp_module_os }, \
91+
92+
#define MICROPY_PORT_ROOT_POINTERS \
93+
mp_obj_t keyboard_interrupt_obj;
94+
95+
//////////////////////////////////////////
96+
// Do not change anything beyond this line
97+
//////////////////////////////////////////
98+
8699
// Define to 1 to use undertested inefficient GC helper implementation
87100
// (if more efficient arch-specific one is not available).
88101
#ifndef MICROPY_GCREGS_SETJMP
@@ -93,13 +106,6 @@
93106
#endif
94107
#endif
95108

96-
#define MICROPY_ENABLE_EMERGENCY_EXCEPTION_BUF (0)
97-
98-
extern const struct _mp_obj_module_t mp_module_os;
99-
100-
#define MICROPY_PORT_BUILTIN_MODULES \
101-
{ MP_OBJ_NEW_QSTR(MP_QSTR_uos), (mp_obj_t)&mp_module_os }, \
102-
103109
// type definitions for the specific machine
104110

105111
#ifdef __LP64__
@@ -124,9 +130,6 @@ typedef long mp_off_t;
124130
typedef void *machine_ptr_t; // must be of pointer size
125131
typedef const void *machine_const_ptr_t; // must be of pointer size
126132

127-
#define MICROPY_PORT_ROOT_POINTERS \
128-
mp_obj_t keyboard_interrupt_obj;
129-
130133
// We need to provide a declaration/definition of alloca()
131134
#ifdef __FreeBSD__
132135
#include <stdlib.h>

0 commit comments

Comments
 (0)