|
Re: Editor underlines string_view as error [message #1842144 is a reply to message #1842126] |
Thu, 10 June 2021 08:26 |
David Vavra Messages: 1426 Registered: October 2012 |
Senior Member |
|
|
Properties --> C/C++ Build --> Settings are only used for building Makefiles in a Managed Build project.
In fact, they are only present in such a project.
You also need to change the the builtin provider command to alert the Indexer.
The default standard for GCC depends on the GCC version.
Some (mine for instance, 9.3.1 20200408) default to c++14
Here's the latest from GNU: https://gcc.gnu.org/projects/cxx-status.html
Says 2014 C++ standard is the default from GCC 6.1 up through GCC 10.
Add -std=c++17 to the provider command at
Properties --> C/C++ General --> Preprocessor Include Paths, Macros etc. --> Providers tab
${COMMAND} -std=c++17 ${FLAGS} -E -P -v -dD "${INPUTS}"
The provider doesn't always run right away.
May not take effect until the next build.
Forcing a console to be allocated to it sometimes causes it to run.
You may still need to rebuild the index.
The value for __cplusplus should be greater than or equal to 201703L.
You could also add it to the User Settings Entries on the Entries tab.
---
Please don't embed such large images.
The web software use by Eclipse doesn't handle it well.
Smaller screens may not get a horizontal scroll bar.
And even when they do, it forces constant scrolling to read the post.
It's one of the reasons why I put sentences on separate lines.
[Updated on: Thu, 10 June 2021 09:13] Report message to a moderator
|
|
|
Powered by
FUDForum. Page generated in 0.02384 seconds