NoQ added inline comments.

================
Comment at: lib/StaticAnalyzer/Checkers/PthreadLockChecker.cpp:271
     }
-    assert(lockFail && lockSucc);
-    C.addTransition(lockFail);
-
+    // We might want to handle the case when the mutex lock function was 
inlined
+    // and returned an Unknown or Undefined value.
----------------
zaks.anna wrote:
> This comment is repeated several times...
Because it is relevant in both places. Should i rephrase with "also"/"as 
well"/"here too"?


================
Comment at: test/Analysis/Inputs/system-header-simulator-for-pthread-lock.h:29
+extern void lck_mtx_unlock(lck_mtx_t *);
+extern boolean_t lck_mtx_try_lock(lck_mtx_t *);
 extern void lck_mtx_destroy(lck_mtx_t *lck, lck_grp_t *grp);
----------------
zaks.anna wrote:
> Should there be a test added that uses the function?
The tests are already there for all three functions. I just fixed their 
prototype to match the real-world prototype, and then adjusted the code 
accordingly, so that the existing tests kept passing.


https://reviews.llvm.org/D37806



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

Reply via email to