Closed balazske closed 5 years ago
Trying to create a test but it looks more complicated to do.
There are a lot of changes in BugReporterVisitors.cpp that are missing from the Ericsson version. This particular problem is fixed in https://reviews.llvm.org/rC357329 in a better way, probably that should be back-ported. But what about the other changes (these are relatively old changes, probably still not in clang8?)? In a later change https://reviews.llvm.org/rC357810 the whole line with the "problematic" code is removed.
That is a good catch. Unfortunately, there may be fixes which are not in Clang8. Clang8 branch started at 2019.01.16.
I think right now we can leave in your fix, that seems to almost the same what they did in rC357329. And once we change to Clang9 then the later changes will come in.
The called decl may be a function that has no source range (the function is called without existing definition or declaration, this is possible in C89).