This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

VSCode settings

Hello,

I am trying to debug a sample program using VSCode with nRF Connect SDK v1.7.0.

1. #include errors detected based on information provided by the configurationProvider setting. Squiggles are disabled for this translation unit (C:\zephyr\v1.7.0\nrf\samples\event_manager\src\main.c).

2. cannot open source file "event_manager_priv.h" (dependency of "event_manager.h")

Even vscode show errors, the program can successfully build and debug. How can I fix these squiggles errors?

Parents
  • Hi , would it be possible for you to share the output of the "C/C++: Log Diagnostics" command if you run that from the command palette after opening up, say, the main.c file from the project? It would be interesting to see if we're providing the correct include paths to the C/C++ intellisense.

    I can reproduce the issue you are seeing if there is no build for the project as we rely on the information in the build folder (specifically the compile_commands.json file) to figure out the exact include paths required for the project and we provide those to the C/C++ extension as part of a config value. If I do a build of the project, then it starts to work ok though as the build & include information is there.

Reply
  • Hi , would it be possible for you to share the output of the "C/C++: Log Diagnostics" command if you run that from the command palette after opening up, say, the main.c file from the project? It would be interesting to see if we're providing the correct include paths to the C/C++ intellisense.

    I can reproduce the issue you are seeing if there is no build for the project as we rely on the information in the build folder (specifically the compile_commands.json file) to figure out the exact include paths required for the project and we provide those to the C/C++ extension as part of a config value. If I do a build of the project, then it starts to work ok though as the build & include information is there.

Children
No Data
Related