[cfe-dev] Extend Static Analyzer

ajotwani ajotwani85 at gmail.com
Wed Jun 29 10:46:56 PDT 2011


Thanks for the reply to the question about extending the static analyzer. I
have followed your recommendation and have added a simple self contained
checker to lib/StaticAnalyzer/Checkers that implements some very basic
warnings if it sees certain function calls for file access (e.g.
'writeToFile' in Objective C). I modeled the checker against the
UnixAPIChecker.cpp and MacOSXAPIChecker.cpp. I also added the declaration of
the checker to lib/StaticAnalyzer/Checkers/Checkers.td. 

Is there anywhere else I need to add anything to get this working? I am
assuming the checker will be invoked when a function call happens based on
check::PreStmt<CallExpr>, which I included from the UnixAPIChecker and
MacOSXAPIChecker checkers. 

--
View this message in context: http://clang-developers.42468.n3.nabble.com/Extend-Static-Analyzer-tp3120000p3122610.html
Sent from the Clang Developers mailing list archive at Nabble.com.



More information about the cfe-dev mailing list