I have a .h file here that is C code, but looking at the violations reported by Sonar it appears that it is interpreted as C++. For example, the violation “move declaration to a namespace” is reported.
I have a little idea why this happens: we have a “core” code in C and “unit testing” code in C++, both use the same .h file.
Could you confirm if what I’m supposing is true ? What is the behavior of Sonar in such cases ?