2026-01-13 12:09 AM
Hello everyone,
I am facing an issue with the STM32CubeIDE V1.17.0 indexer, where it highlights a syntax error when using the C11 _Generic primitive. Due to company project policies, I cannot upgrade to a newer version of the IDE at this time, so I need to find a solution or workaround for V1.17.0.
The indexer flags the code as a "Syntax error" as shown in the attached image:
The PAR_SET macro is defined as follows:
Key details:
There are no missing includes or path issues.
The code compiles successfully without any errors or warnings (GCC is happy).
Runtime performance is intact, and the macro functions exactly as expected.
The problem seems to be strictly with the indexer being unable to parse the C11 _Generic keyword correctly. Has anyone encountered this or found a way to "hint" the correct syntax to the indexer?
Any suggestions are greatly appreciated!
Best regards, Žiga
Solved! Go to Solution.
2026-01-13 3:11 AM - edited 2026-01-13 3:14 AM
@CTapp.1 wrote:Probably the same underlying issue as reported here and here
Indeed!
@CTapp.1 wrote:basically seems to be a known Eclipse issue related to C11 language features.
although the 2nd one isn't to do with C11 - it's GCC-specific "attribute" stuff.
Another one here - with C23
@zmiga in conclusion, this is a known "feature" of the Eclipse syntax analyser.
And it's not unique to Eclipse - other IDEs (eg, MSVC) also have similar "features" with their syntax analysers.
2026-01-13 2:09 AM
Probably the same underlying issue as reported here and here - basically seems to be a known Eclipse issue related to C11 language features.
2026-01-13 3:11 AM - edited 2026-01-13 3:14 AM
@CTapp.1 wrote:Probably the same underlying issue as reported here and here
Indeed!
@CTapp.1 wrote:basically seems to be a known Eclipse issue related to C11 language features.
although the 2nd one isn't to do with C11 - it's GCC-specific "attribute" stuff.
Another one here - with C23
@zmiga in conclusion, this is a known "feature" of the Eclipse syntax analyser.
And it's not unique to Eclipse - other IDEs (eg, MSVC) also have similar "features" with their syntax analysers.