NoQ added a comment.

You're on the right track but your checker repeats `PthreadLockChecker` 
word-by-word. Like, you can find answers to all your questions (eg., "how to 
use `isLiveRegion`?") by reading that checker. C++ functions aren't any 
different from C functions; that's an extremely minor difference that doesn't 
justify developing a new checker from scratch.



================
Comment at: clang/lib/StaticAnalyzer/Checkers/ThreadPrimitivesChecker.cpp:34
+
+static const std::pair<FuncIdKind, CallDescription> FuncMapping[]{
+    {Mutex_Lock, {{"std", "mutex", "lock"}, 0, 0}},
----------------
`CallDescriptionMap` is the modern API for this stuff.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D85431/new/

https://reviews.llvm.org/D85431

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to