Template for a good new topic, formatted with Markdown:
ALM used:Azure DevOps
CI system used: Azure DevOps, self hosted agent
Scanner command used when applicable: SonarCloudAnalyze@4.2.5
Languages of the repository C++23, C#
Error observed (wrap logs/code around with triple quotes ``` for proper formatting)
Steps to reproduce
To keep the logger local to the tranlsation unit, it is defined in an anonymous workspace inside the ixx module partion file. This is reported as Add a name to this namespace.
Apologies for the late reply and thanks for reporting this issue.
I was able to reproduce it on my side with the following minimal example:
// Module.cppm
export module mod;
namespace { // FP S1000:Add a name to this namespace.
}
// Implementation.cpp
module mod;
To clarify. Does your module interface unit also have a corresponding module implementation unit? From my debugging, this is the necessary condition to trigger this false positive.
In any case, I’ve created a ticket to fix this. But let me know if your case is actually different.