micropython/unix
Alexander Steffen 299bc62586 all: Unify header guard usage.
The code conventions suggest using header guards, but do not define how
those should look like and instead point to existing files. However, not
all existing files follow the same scheme, sometimes omitting header guards
altogether, sometimes using non-standard names, making it easy to
accidentally pick a "wrong" example.

This commit ensures that all header files of the MicroPython project (that
were not simply copied from somewhere else) follow the same pattern, that
was already present in the majority of files, especially in the py folder.

The rules are as follows.

Naming convention:
* start with the words MICROPY_INCLUDED
* contain the full path to the file
* replace special characters with _

In addition, there are no empty lines before #ifndef, between #ifndef and
one empty line before #endif. #endif is followed by a comment containing
the name of the guard macro.

py/grammar.h cannot use header guards by design, since it has to be
included multiple times in a single C file. Several other files also do not
need header guards as they are only used internally and guaranteed to be
included only once:
* MICROPY_MPHALPORT_H
* mpconfigboard.h
* mpconfigport.h
* mpthreadport.h
* pin_defs_*.h
* qstrdefs*.h
2017-07-18 11:57:39 +10:00
..
coverage-frzmpy tests: Improve frozen import test coverage. 2017-01-16 16:59:03 +11:00
coverage-frzstr tests/unix/extra_coverage: Add tests for importing frozen packages. 2017-01-08 22:45:55 +11:00
modules unix: Move upip to frozen bytecode dir. 2017-05-12 18:32:25 +03:00
.gitignore unix: Fix freedos port build problems. 2017-02-06 15:25:42 +11:00
Makefile unix/Makefile: Disable assertions in the standard unix executable. 2017-07-12 11:57:03 +10:00
alloc.c unix: Convert mp_uint_t to size_t in alloc.c. 2017-03-31 13:18:47 +11:00
coverage.c py/repl: Change mp_uint_t to size_t in repl helpers. 2017-07-04 23:44:54 +10:00
fatfs_port.c unix/fatfs_port: Include new oofatfs header. 2017-01-27 23:22:15 +11:00
fdfile.h all: Unify header guard usage. 2017-07-18 11:57:39 +10:00
file.c py: Add iter_buf to getiter type method. 2017-02-16 18:38:06 +11:00
gccollect.c unix: fix symbol references for x86 Mac 2016-11-02 00:42:04 +03:00
input.c unix: Convert to use core-provided version of built-in import(). 2017-06-01 16:02:49 +10:00
input.h all: Unify header guard usage. 2017-07-18 11:57:39 +10:00
main.c unix/main: Implement -m option for packages. 2017-05-09 14:22:21 +03:00
modffi.c all: Make more use of mp_raise_{msg,TypeError,ValueError} helpers. 2017-06-15 11:54:41 +10:00
modjni.c all: Make more use of mp_raise_{msg,TypeError,ValueError} helpers. 2017-06-15 11:54:41 +10:00
modmachine.c unix/modmachine: Add Signal class to machine module. 2017-03-02 16:08:20 +11:00
modos.c unix: Use mp_obj_str_get_str instead of mp_obj_str_get_data. 2017-03-25 19:54:07 +11:00
modsocket.c unix/modsocket: Remove unnecessary asserts. 2017-07-12 11:43:35 +10:00
modtermios.c unix: Use mp_obj_str_get_str instead of mp_obj_str_get_data. 2017-03-25 19:54:07 +11:00
modtime.c unix/modtime: Replace strftime() with localtime(). 2017-06-11 21:16:35 +03:00
moduos_vfs.c ports: Add ilistdir in uos module. 2017-05-10 12:13:53 +10:00
moduselect.c unix/moduselect: Properly implement ipoll object iteration. 2017-03-05 13:51:22 +01:00
mpconfigport.h unix: Convert to use core-provided version of built-in import(). 2017-06-01 16:02:49 +10:00
mpconfigport.mk unix/mpconfigport.mk: Update descriptions of readline and TLS options. 2017-06-17 15:44:28 +03:00
mpconfigport_coverage.h unix: Enabled high-quality float hashing in coverage build. 2017-04-12 13:38:17 +10:00
mpconfigport_fast.h py: Add ability to have frozen persistent bytecode from .mpy files. 2016-04-13 16:07:47 +01:00
mpconfigport_freedos.h unix: Fix freedos port build problems. 2017-02-06 15:25:42 +11:00
mpconfigport_minimal.h unix, windows: Use core-provided KeyboardInterrupt exception object. 2017-04-11 13:31:49 +10:00
mpconfigport_nanbox.h unix: Add option to build 64-bit NaN-boxing interpreter. 2016-01-15 11:12:08 +00:00
mphalport.h unix: Convert to use core-provided version of built-in import(). 2017-06-01 16:02:49 +10:00
mpthreadport.c unix: Use mp_raise_OSError helper function. 2016-10-07 14:05:15 +11:00
mpthreadport.h all: Unify header guard usage. 2017-07-18 11:57:39 +10:00
qstrdefsport.h py: Add rules for automated extraction of qstrs from sources. 2016-04-16 13:18:09 +01:00
unix_mphal.c unix, windows: Use core-provided KeyboardInterrupt exception object. 2017-04-11 13:31:49 +10:00