-
Notifications
You must be signed in to change notification settings - Fork 236
Setup the include paths automatically #1148
Comments
@Stig124 Which version of the extension are you using? v0.3.4 added a fix to intelliSense that resolves most issues, you might need to recreate the c_cpp_properties.json file. To do that open the .vscode folder and delete the file, then open the board manager and reselect the board you're using. #1141 should fix all the issues once we merge it in. |
really ? I currently work on an ESP8266 ESP12E project. It has multiple .ino files, uses libraries from the core and local libs. The main sketch file myproject.ino holds the globals declarations and functions prototypes. Functions definitions are in separated files. It compiles fine with both Arduino IDE 1.8.1.3 (latest) and VSCode Arduino 0.3.4. The brand new c_cpp_properties.json file, generated by 0.3.4, is like this :
I had to add "ARDUINO=10813" in the defines because many libraries check on the Arduino version. With these setting, VSCode arduino 0.3.4 reports 340 errors in my code. All are false positives. Then I added this line to forcedInclude : (see my comment #271 (comment))
This should be useless, because this path is already in the include path. But it is not ! Then I added a second line to forcedInclude
Again, this line should be useless, but it is not. With this, the number of false positive errors goes down to 31. That is still a lot! Here are examples of the remaining 31 false positive reported. Example 1: configTime Example 2: Example 3: nullptr |
@alka79 I think what I should have said was is that some issues were resolved in v0.3.4, but we're still working on a more permanent solution. I should be able to get a fix out for the first two issues you have, I'll look into the last one and see what I can do. |
looking forward to it :) Is there a precedence order in the paths listed in includePath and forcedInclude ? |
Tracking this with #438 |
I have a recurring issue with the VSCode Arduino ext, I work with many libraires and every single one breaks the spellchecking (include issues), I managed to make a workaround but it's still a pain
It would be nice if the extension could prefill the include paths automatically
The text was updated successfully, but these errors were encountered: