mes/include/mes
Jan (janneke) Nieuwenhuizen 19a4f9df0b
core: Prepare for M2-Planet: mes.c.
Rewrite C-constructs not supported by M2-Planet, such as

    foo ? bar : baz;       -> if (foo) bar; else baz;
    static char foo[1024]  -> __func_buf = malloc (1024); ... char *foo = __func_buf;
    *foo                   -> foo[0]
    foo++                  -> foo = foo + 1   TODO: pointer arithmetic
    foo += 1;              -> foo = foo + 1
    for (int foo = ;       -> int foo; for (foo=
    if (foo)               -> if (foo != 0)
    if (!foo)              -> if (foo == 0)
    ;                      -> 0;
    // ...                 -> /* ... */

* src/mes.c: Rewrite C constructs not supported by M2-Planet.
* include/mes/mes.h (__execl_c_argv, __getcwd_buf, __open_boot_buf,
__open_boot_file_name, __setenv_buf, __reader_read_char_buf): Declare
buffers.
(init): Initialize them.
* include/mes/macros.h(__M2_PLANET__): Temporary M2 macros.
2020-04-19 13:18:09 +02:00
..
builtins.h core: Prepare for M2-Planet: mes.c. 2020-04-19 13:18:09 +02:00
cc.h core: Prepare for M2-Planet: mes.c. 2020-04-19 13:18:09 +02:00
constants.h core: Prepare for M2-Planet: mes.c. 2020-04-19 13:18:09 +02:00
lib-mini.h mescc: Mes C Library: Support gcc-10. 2020-10-06 13:13:44 +02:00
lib.h mescc: Mes C Library: Declare __mesabi_uldiv. 2021-01-23 08:43:46 +01:00
m2.h core: Prepare for M2-Planet: mes.c. 2020-04-19 13:18:09 +02:00
macros.h build: Simplify. 2019-06-08 15:36:22 +02:00
mes.h core: Prepare for M2-Planet: mes.c. 2020-04-19 13:18:09 +02:00