Fix web simulator and binpack build (#114)

This commit is contained in:
Yaya-Cout
2021-12-28 15:12:13 +01:00
committed by GitHub
parent 398e974ccd
commit 70b162e63b
7 changed files with 9 additions and 52 deletions

View File

@@ -5,7 +5,6 @@
/* MicroPython configuration options
* We're not listing the default options as defined in mpconfig.h */
#if __EMSCRIPTEN__
// Enable a PyStack where most objects are allocated instead of always using the heap
/* This enables to allocate and free memory in a scope (thus, Python can call
* Python) but also has the collateral effect of removing bugs regarding
@@ -15,8 +14,7 @@
* collecting roots the transpiled C code is denied access to Javascript
* variables that can store pointers to the Python heap. The pointed objects
* are therefore erased prematurely. */
#define MICROPY_ENABLE_PYSTACK (1)
#endif
#define MICROPY_ENABLE_PYSTACK (0)
// Maximum length of a path in the filesystem
#define MICROPY_ALLOC_PATH_MAX (32)

View File

@@ -163,10 +163,6 @@ extern "C" {
}
void MicroPython::init(void * heapStart, void * heapEnd) {
#if __EMSCRIPTEN__
static mp_obj_t pystack[1024];
mp_pystack_init(pystack, &pystack[MP_ARRAY_SIZE(pystack)]);
#endif
/* We delimit the stack part that will be used by Python. The stackTop is the
* address of the first object that can be allocated on Python stack. This
* boundaries are used: