VS Code Microsoft C/C++ Extension 在常见的包含部分显示错误。

huangapple go评论70阅读模式
英文:

VS Code Microsoft C/C++ Extension showing errors on usual includes

问题

我已经有这个问题几个小时了,而且我解决不了:

#include errors detected. Please update your includePath. Squiggles are disabled for this translation unit (D:\\Bureau\\c++\\\tower.cpp).

当我将光标移到 #include <iostream> 上时,我收到这条消息:无法打开源文件 "iostream"。

有没有一种方法可以解决这个问题(不仅仅是每次打开应用程序时修改 vscode 文件)?

谢谢

检查了 MINGW 路径是可写的,并且它是正确的,而且在 bash 中使用 --version 是正常的。

英文:

I have this problem since a couple of hours and I can't fix it :

#include errors detected. Please update your includePath. Squiggles are disabled for this translation unit (D:\\Bureau\\c++\\\tower.cpp).

And i have this message while passing my cursor on this #include <iostream> :
cannot open source file "iostream"

Is there a method to fix this (not just modifying a vscode file every time I open the app) ?

Thanks

Checked that the MINGW path is write and it is good, plus working in bash with --version

答案1

得分: 0

我刚刚不得不将这个路径添加到我的includePath中,出于某种原因它是另一个路径。

C:\Program Files (x86)\Microsoft VisualStudio22\BuildTools\VC\Tools\MSVC.34.31933\bin\Hostx64\x64
英文:

I just had to put this path to my includePath, for some reasons it was another one.

C:\Program Files (x86)\Microsoft VisualStudio22\BuildTools\VC\Tools\MSVC.34.31933\bin\Hostx64\x64

huangapple
  • 本文由 发表于 2023年2月16日 07:57:24
  • 转载请务必保留本文链接:https://go.coder-hub.com/75466536.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定