diff options
author | Thiago Macieira <thiago.macieira@intel.com> | 2016-06-21 16:33:57 -0700 |
---|---|---|
committer | Thiago Macieira <thiago.macieira@intel.com> | 2016-07-02 02:02:34 +0000 |
commit | d72ac3f35f4c6d6405e9675d54124b3ddb8d80ab (patch) | |
tree | 4fe658f22c2b9f6089bec46aa1075472bcf110d9 | |
parent | 5b66f4ba400d0f9550e14874eb7d42f3c43e3027 (diff) |
moc: remove _MSC_EXTENSIONS #define
Because we obviously don't support Microsoft's extensions in C++. This
is required because some MS headers have code that isn't proper C++,
like iso646.h:
#if !defined(__cplusplus) || defined(_MSC_EXTENSIONS)
#define and &&
Change-Id: Ib57b52598e2f452985e9fffd145a3d4ec28e773d
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
-rw-r--r-- | src/tools/moc/main.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/tools/moc/main.cpp b/src/tools/moc/main.cpp index 491301d582..0c327a641f 100644 --- a/src/tools/moc/main.cpp +++ b/src/tools/moc/main.cpp @@ -422,6 +422,9 @@ int runMoc(int argc, char **argv) // 1. preprocess moc.symbols = pp.preprocessed(moc.filename, &in); + // We obviously do not support MS extensions + pp.macros.remove("_MSC_EXTENSIONS"); + if (!pp.preprocessOnly) { // 2. parse moc.parse(); |