Skip to content
Snippets Groups Projects
Commit 9da46a98 authored by stijn's avatar stijn Committed by Damien George
Browse files

windows/mpconfigport.h: Don't define restrict/inline/alignof for C++.

The C++ standard forbids redefining keywords, like inline and alignof, so
guard these definitions to avoid that, allowing to include the MicroPython
headers by C++ code.
parent a2933476
No related branches found
No related tags found
No related merge requests found
......@@ -228,9 +228,11 @@ extern const struct _mp_obj_module_t mp_module_time;
// CL specific definitions
#ifndef __cplusplus
#define restrict
#define inline __inline
#define alignof(t) __alignof(t)
#endif
#define PATH_MAX MICROPY_ALLOC_PATH_MAX
#define S_ISREG(m) (((m) & S_IFMT) == S_IFREG)
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment