Imported project has incorrect highlighting for preprocessor conditional macros

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Imported project has incorrect highlighting for preprocessor conditional macros

96 Views
anthony_asterisk
Contributor II

I have a project imported to MCUXpresso for VSCode extension.

The extension has detected the repository as a zephyr repository and can build the default Build Configuration. 

When I load c files from the project, they do not have the correct set of preprocessor conditions highlighted.  It is only showing the default (nothing defined) path when in reality there are many variables set through KConfig (zephyr).

How do I configure the intellisense highlighting to be based on the cmake generated configuration that is used during the build?

@dereksnell maybe you have some hints? 

 

0 Kudos
1 Reply

34 Views
HangZhang
NXP Employee
NXP Employee

Hi @anthony_asterisk 

To ensure that IntelliSense recognizes these settings and highlights them, you need to ensure that the VS Code correctly loads the configuration file generated by CMake, and it is recommended to use the CMakePresets.json file to configure the build settings. This file is directly supported by CMake.
If the problem persists, it may be necessary to check if your compiler and build toolchain are installed correctly.

Hope this will help you.

BR

Hang

0 Kudos