Reputation: 1193
I'm using Eclipse Mars.2 Release (4.5.2) in Windows. C++11 works well, but for C++14, I can build and run a project using C++14 features without any error, but the IDE always highlights errors in the lines using C++14 features, it makes me difficult to detect real errors.
E.g. When using std::make_unique, it always highlight a bug symbol with notification "Symbol 'make_unique' could not be resolved".
How do I enable C++14 Syntax checking in Eclipse?
My current configuration:
Project property -> C/C++ build -> Setting -> Preprocessor -> Defined symbols:
Project property -> C/C++ build -> Setting -> Miscellaneous-> other flags:
Upvotes: 7
Views: 8632
Reputation: 21
Keeping the Project property -> C/C++ build -> Setting -> Miscellaneous-> other flags:
-c fmessage-length=0 -std= c++0x
should work..
Upvotes: 1
Reputation: 338
You are going at this the wrong way. To change the compiler and indexer, go to Properties -> C/C++ Build -> Settings. Under GCC C++ Compiler select the Dialect menu. In the Language standard drop down, select C++1y. I don't think the support is full yet however.
Upvotes: 6