8000 unix/modffi: Move header includes inside MICROPY_PY_FFI guard. · jimmo/micropython@89b3207 · GitHub
[go: up one dir, main page]

Skip to content

Commit 89b3207

Browse files
committed
unix/modffi: Move header includes inside MICROPY_PY_FFI guard.
So ffi.h is not needed if this module is disabled. Signed-off-by: Damien George <damien@micropython.org>
1 parent ab317a0 commit 89b3207

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

ports/unix/modffi.c

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,6 @@
2525
* THE SOFTWARE.
2626
*/
2727

28-
#include <assert.h>
29-
#include <string.h>
30-
#include <errno.h>
31-
#include <dlfcn.h>
32-
#include <ffi.h>
33-
#include <stdint.h>
34-
3528
#include "py/runtime.h"
3629
#include "py/binary.h"
3730
#include "py/mperrno.h"
@@ -40,6 +33,12 @@
4033

4134
#if MICROPY_PY_FFI
4235

36+
#include <assert.h>
37+
#include <string.h>
38+
#include <errno.h>
39+
#include <dlfcn.h>
40+
#include <ffi.h>
41+
4342
/*
4443
* modffi uses character codes to encode a value type, based on "struct"
4544
* module type codes, with some extensions and overridings.

0 commit comments

Comments
 (0)
0