| Commit message (Collapse) | Author | Age |
|
|
|
|
| |
make is not always GNU make; the latter may go by different names.
This helps builds on systems where the default make is not GNU make.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
For x86_64 build, this saves only 128 bytes on the final executable
size, but still an improvement.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
This will lead to crash like:
FATAL: uncaught NLR 80a5420
On x86_32, the minimum heap size is smaller, but not 2 times, so just
use value which works for x86_64.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The with semantics of this function is close to
pkg_resources.resource_stream() function from setuptools, which
is the canonical way to access non-source files belonging to a package
(resources), regardless of what medium the package uses (e.g. individual
source files vs zip archive). In the case of MicroPython, this function
allows to access resources which are frozen into the executable, besides
accessing resources in the file system.
This is initial stage of the implementation, which actually doesn't
implement "package" part of the semantics, just accesses frozen resources
from "root", or filesystem resource - from current dir.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Do not raise SIGPIPE, instead return EPIPE. Otherwise, e.g. writing
to peer-closed socket will lead to sudden termination of MicroPython
process. SIGPIPE is particularly nasty, because unix shell doesn't
print anything for it, so the above looks like completely sudden and
silent termination for unknown reason. Ignoring SIGPIPE is also what
CPython does. Note that this may lead to problems using MicroPython
scripts as pipe filters, but again, that's what CPython does. So,
scripts which want to follow unix shell pipe semantics (where SIGPIPE
means "pipe was requested to terminate, it's not an error"), should
catch EPIPE themselves.
|
|
|
|
|
| |
It doesn't do anything. The VFS feature is controlled by MICROPY_VFS and
the FatFS driver, by MICROPY_VFS_FAT (which are set in mpconfigport.h).
|
|
|
|
|
|
| |
Prior to making this a config option it was previously available on these
(and all other) ports, and it makes sense to keep it enabled for mpy-cross
as well as ports that have a decent amount of space for the code.
|
| |
|
| |
|
|
|
|
|
| |
It can still be overwritten by a port in mpconfigport.h but for almost
all cases one can use the provided default.
|
|
|
|
|
|
|
| |
This follows the pattern of how all other headers are now included, and
makes it explicit where the header file comes from. This patch also
removes -I options from Makefile's that specify the mp-readline/timeutils/
netutils directories, which are no longer needed.
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
The -ansi flag is used for C dialect selection and it is equivalent to -std=c90.
Because it goes right before -std=gnu99 it is ignored as for conflicting flags
GCC always uses the last one.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
The lexer can now raise an exception on construction so it must go within
an nlr handler block.
|
|
|
|
|
| |
TODO: There's another issue to care about: poll set being modified during
iteration.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Allows to iterate over the following without allocating on the heap:
- tuple
- list
- string, bytes
- bytearray, array
- dict (not dict.keys, dict.values, dict.items)
- set, frozenset
Allows to call the following without heap memory:
- all, any, min, max, sum
TODO: still need to allocate stack memory in bytecode for iter_buf.
|
|
|
|
|
|
|
|
|
| |
ipoll() allows to poll streams without allocating any memory: this method
returns an iterator (a poll object itself), and the iterator yields
preallocated "callee-owned tuple" with polling results for each active
stream. The only operation a caller is allowed to do with this tuple is
extracting values from it (storing the tuple as a whole somewhere is
not allowed).
|
|
|
|
|
|
| |
This patch implements support for class methods __delattr__ and __setattr__
for customising attribute access. It is controlled by the config option
MICROPY_PY_DELATTR_SETATTR and is disabled by default.
|
|
|
|
| |
In other words, where first path component is an empty string.
|
| |
|
|
|
|
|
|
| |
Updated modbuiltin.c to add conditional support for 3-arg calls to
pow() using MICROPY_PY_BUILTINS_POW3 config parameter. Added support in
objint_mpz.c for for optimised implementation.
|
| |
|
|
|
|
|
| |
Everyone should now be using the new ooFatFs library. The old one is no
longer supported and will be removed.
|
| |
|
|
|
|
| |
Replaced by MICROPY_VFS and the VFS sub-system.
|
| |
|
|
|
|
|
| |
This patch includes a new module "uos_vfs" which can be used for testing
the VFS syb-system.
|
|
|
|
| |
And move declaration of mp_fat_vfs_type to this file.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|