Wykres commitów

20 Commity (4601759bf59e16b860a3f082e9aa4ea78356bf92)

Autor SHA1 Wiadomość Data
Damien George 4601759bf5 py/objstr: Remove "make_qstr_if_not_already" arg from mp_obj_new_str.
This patch simplifies the str creation API to favour the common case of
creating a str object that is not forced to be interned.  To force
interning of a new str the new mp_obj_new_str_via_qstr function is added,
and should only be used if warranted.

Apart from simplifying the mp_obj_new_str function (and making it have the
same signature as mp_obj_new_bytes), this patch also reduces code size by a
bit (-16 bytes for bare-arm and roughly -40 bytes on the bare-metal archs).
2017-11-16 13:17:51 +11:00
Damien George a3dc1b1957 all: Remove inclusion of internal py header files.
Header files that are considered internal to the py core and should not
normally be included directly are:
    py/nlr.h - internal nlr configuration and declarations
    py/bc0.h - contains bytecode macro definitions
    py/runtime0.h - contains basic runtime enums

Instead, the top-level header files to include are one of:
    py/obj.h - includes runtime0.h and defines everything to use the
        mp_obj_t type
    py/runtime.h - includes mpstate.h and hence nlr.h, obj.h, runtime0.h,
        and defines everything to use the general runtime support functions

Additional, specific headers (eg py/objlist.h) can be included if needed.
2017-10-04 12:37:50 +11:00
Damien George f95e4e7782 extmod/vfs_fat_misc: Remove dot-dirs filter since FatFS already does it. 2017-05-13 18:58:46 +10:00
Damien George d4cd4831b0 extmod/vfs_fat: Replace listdir() with implementation of ilistdir().
VfsFat no longer has the listdir() method.  Rather, if listdir()
functionality is needed then one should use uos.listdir() which will call
VfsFat.ilistdir().
2017-05-10 11:39:28 +10:00
Damien George 0fb27888fc extmod/vfs_fat: Remove unused function fat_vfs_listdir. 2017-01-30 12:26:08 +11:00
Damien George b697c89009 extmod: Merge old fsusermount.h header into vfs.h and vfs_fat.h.
vfs.h is for generic VFS declarations, and vfs_fat.h is for VfsFat
specific things.
2017-01-30 12:26:08 +11:00
Damien George 0bd61d23b9 extmod/vfs_fat: Remove MICROPY_FATFS_OO config option.
Everyone should now be using the new ooFatFs library.  The old one is no
longer supported and will be removed.
2017-01-30 12:26:07 +11:00
Damien George 1808b2e8d5 extmod: Remove MICROPY_FSUSERMOUNT and related files.
Replaced by MICROPY_VFS and the VFS sub-system.
2017-01-30 12:26:07 +11:00
Damien George 3d6f957208 extmod/vfs_fat: Remove MICROPY_FSUSERMOUNT_ADHOC config option. 2017-01-30 12:26:07 +11:00
Damien George ec3274324b extmod/vfs_fat: Update to use FF_DIR instead of DIR. 2017-01-30 12:08:15 +11:00
Damien George 6c23c7587f extmod/vfs: Add ability for VFS sub-system to import using VfsFat. 2017-01-27 17:21:45 +11:00
Damien George 32a1138b9f extmod: Rename vfs_fat_file.h to vfs_fat.h.
And move declaration of mp_fat_vfs_type to this file.
2017-01-27 15:04:17 +11:00
Damien George f5f4cdae89 extmod/vfs_fat: Rework so it can optionally use OO version of FatFS.
If MICROPY_VFS_FAT is enabled by a port then the port must switch to using
MICROPY_FATFS_OO.  Otherwise a port can continue to use the FatFs code
without any changes.
2017-01-27 13:19:10 +11:00
Damien George 620c4c32bf extmod/vfs_fat: Use mp_raise_OSError helper function. 2016-10-07 13:44:55 +11:00
Robert HH 7c004e794c extmod/vfs_fat*: Replace text error messages by POSIX error numbers.
These changes are in line with similar changes in other modules, and
with standard Python interface.
2016-05-27 23:57:01 +03:00
Damien George f9dc644017 extmod: When including extmod headers, prefix path with extmod/. 2016-05-20 12:46:20 +01:00
Paul Sokolovsky 09e363316f extmod/vfs_fat_misc: Fix cc3200 port build. 2016-02-29 01:15:19 +02:00
Paul Sokolovsky 08fed6992f extmod/vfs_fat_misc: Add func prototype for pedantic warnings. 2016-02-29 00:48:45 +02:00
Paul Sokolovsky 6ef65e70af extmod/vfs_fat: Add fat_vfs_import_stat(), reusable import stat routine.
Moved from stmhal.
2016-02-29 00:44:32 +02:00
Paul Sokolovsky cd6d189f48 extmod/vfs_fat: Move listdir() method from stmhal for reuse. 2016-02-28 17:17:24 +02:00