Skip to content

Commit 3adb8cb

Browse files
committed
Add a FAQ for getting IntelliSense to work with MinGW on Windows
1 parent 6df6c11 commit 3adb8cb

File tree

1 file changed

+8
-0
lines changed
  • Documentation/LanguageServer

1 file changed

+8
-0
lines changed

Documentation/LanguageServer/FAQ.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
[Why do I have red underlines everywhere after updating to the latest version](#why-do-i-have-red-underlines-everywhere-after-updating-to-the-latest-version)?
44

5+
[How do I get the new IntelliSense to work with MinGW on Windows](#how-do-i-get-the-new-intellisense-to-work-with-mingw-on-windows)?
6+
57
[What is the difference between "includePath" and "browse.path" in c\_cpp\_properties.json](#what-is-the-difference-between-includepath-and-browsepath-in-c_cpp_propertiesjson)?
68

79
## Why do I have red underlines everywhere after updating to the latest version?
@@ -26,6 +28,12 @@ If you want to keep using the semantic-aware features that will be coming online
2628

2729
If you were happy with the old behavior of the extension or want to wait to get the semantic-aware features until build system support arrives in the extension so that you don't have to manually configure a c_cpp_properties.json file, you can disable the new IntelliSense engine entirely by adding `"intelliSenseEngine": "Tag Parser"` to your settings.json file.
2830

31+
## How do I get the new IntelliSense to work with MinGW on Windows?
32+
33+
On Windows PCs, the new IntelliSense engine is configured to compile your source files in Microsoft mode. But since MinGW is a relative of GCC, Microsoft mode compilation doesn't work very well with it. While the IntelliSense engine supports compiling code in clang/gcc mode, the extension does not currently expose any settings that allow you to configure it.
34+
35+
You can, however, override the engine's configuration by changing the contents of the `%userprofile%\.vscode\extensions\ms-vscode.cpptools-0.11.1\bin\msvc.64.intel.json` file. In fact, copying `msvc.64.linux.json` over `msvc.64.intel.json` will reconfigure the engine to compile your source code in clang mode. The caveat is that making changes to the `msvc.64.intel.json` is not a permanent operation. The next time you upgrade the extension, your changes will be reverted. However, this workaround should be able to enable you to use the new IntelliSense engine with MinGW until we have time to expose a proper setting.
36+
2937
## What is the difference between "includePath" and "browse.path" in c\_cpp\_properties.json?
3038

3139
Starting with version 0.11.0 of the cpptools extension, there are now two settings in the c\_cpp\_properties.json file. They are used by the different IntelliSense engines that we support and have slightly different meanings for the components that use them.

0 commit comments

Comments
 (0)