vscode-cpptools icon indicating copy to clipboard operation
vscode-cpptools copied to clipboard

cppStandard no longer seems to be respected on insiders version

Open duncanhorn opened this issue 7 years ago • 3 comments

Type: LanguageService

Describe the bug

  • OS and Version: Windows 1803(?) update
  • VS Code Version: 1.34.0-insiders
  • C/C++ Extension Version: 0.23.0-insiders

To Reproduce

  1. Have the above installed.
  2. Create a blank directory and open it in Code Insiders
  3. Create a new cpp file and write the contents:
#include <string_view>

std::string_view s = "foo";

There will be red squiggles on std::string_view. You can edit the c_cpp_properties.json file to include the line "cppStandard": "c++17", but that doesn't seem to help. No matter what the deduced C++ version is always less than C++17 (C++14?).

Expected behavior Once adding "cppStandard": "c++17" to the configuration file, C++17 features should not give intellisense errors.

duncanhorn avatar Apr 26 '19 09:04 duncanhorn

Thanks a lot for reporting this -- it'll be fixed for our next update (probably Monday).

The bug repros with msvc-x64 mode.

sean-mcmanus avatar Apr 26 '19 23:04 sean-mcmanus

Thanks for the quick turnaround!

duncanhorn avatar Apr 27 '19 03:04 duncanhorn

@Lennon925 The C++17 problem should be fixed with 0.23.0-insiders2: https://github.com/Microsoft/vscode-cpptools/releases/tag/0.23.0-insiders2

There might be some C++20 features incorrectly enabled, but we plan to add a new setting for that later.

sean-mcmanus avatar May 02 '19 00:05 sean-mcmanus