<div dir="ltr">I'm working on a simple checker for objc block calls and faced some strange behaviour of ConstraintsManager.<div><br></div><div>Even for simple case like this:</div><br>- (void) callObjcBlock:(void(^)(void)) blockVar {<br>    blockVar();<br>}<div><br></div><div>ConstraintsManager believes that called 'blockVar' is constrained to be non null, not unknown.</div><div><br></div><div>I have noticed that with disabled 'CallAndMessageChecker' ConstraintsManager begins to work correctly.</div><div><br></div>I believe that managed to localise the problematic code. At the end of 'CallAndMessageChecker::checkPreStmt' method at CallAndMessageChecker.cpp. StNonNull state is added as transition to CheckerContext without prior checking that StNull is nullptr.


<div><br></div><div>Isn't it would be more correct to write it this way:</div><div><br></div>  if(!StNull) {<br>    C.addTransition(StNonNull);<br>  }<div><br></div><div>Could someone suggest me should or should not it be fixed ?</div></div>