[clang] [analyzer] Improve diagnostics from ArrayBoundCheckerV2 (PR #70056)

Balazs Benics via cfe-commits cfe-commits at lists.llvm.org
Tue Oct 31 10:50:23 PDT 2023


=?utf-8?q?Donát?= Nagy <donat.nagy at ericsson.com>,
=?utf-8?q?Donát?= Nagy <donat.nagy at ericsson.com>
Message-ID:
In-Reply-To: <llvm/llvm-project/pull/70056 at github.com>


================
@@ -22,23 +22,25 @@
 #include "clang/StaticAnalyzer/Core/PathSensitive/DynamicExtent.h"
 #include "clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h"
 #include "llvm/ADT/SmallString.h"
+#include "llvm/Support/FormatVariadic.h"
 #include "llvm/Support/raw_ostream.h"
 #include <optional>
 
 using namespace clang;
 using namespace ento;
 using namespace taint;
+using llvm::formatv;
 
 namespace {
+enum OOB_Kind { OOB_Precedes, OOB_Exceeds, OOB_Taint };
----------------
steakhal wrote:

FYI you can use any identifiers here because these are only exposed to this single TU.
The ugly prefixes are only applied to enums exposed in headers etc. where there is an unbounded chance of having collisions.
No action is expected.

https://github.com/llvm/llvm-project/pull/70056


More information about the cfe-commits mailing list