[cfe-dev] [analyzer] template instantiations, multiple reports
Devin Coughlin via cfe-dev
cfe-dev at lists.llvm.org
Mon Oct 12 14:18:46 PDT 2015
> On Oct 9, 2015, at 8:00 AM, Alexander Droste via cfe-dev <cfe-dev at lists.llvm.org> wrote:
>
> Hi,
>
> does the analyzer always produce multiple reports
> if the detected error is in a template that gets instantiated
> in multiple translation units or is the check itself
> then doing something wrong if bugs get reported more than once?
The analyzer does not do any cross-translation unit uniquing. So if an error is detected in the same header in multiple translation units it will get reported multiple times. Also, if the analyzer notices that the last component of path diagnostic is in a header, it will try to report the diagnostic at the last location along the path in the mail file (see PathDiagnostic::resetDiagnosticLocationToMainFile()).
Devin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20151012/a4775eaa/attachment.html>
More information about the cfe-dev
mailing list