<div dir="ltr"><div><div><div>Hi there,<br><br></div>I am working on a system to model API calls in the Static Analyzer. The main idea is to have C/C++ source files that contains definitions of functions and methods, and they are parsed by Clang and used by the Static Analyzer when the definition of a function or a method is in another translation unit. This can help the analyzer to find more possible issues when known APIs are modelled. (More details on my GSoC project page: <a href="http://www.google-melange.com/gsoc/project/details/google/gsoc2014/xazax/5717271485874176">http://www.google-melange.com/gsoc/project/details/google/gsoc2014/xazax/5717271485874176</a>)<br>
<br></div>The patch I attached can parse a model file using the ASTContext of the currently analyzed translation unit, so the model files do not need to be a standalone translation units and they can be parsed quickly. Any review on my current implementation is welcome. Because the error reporting is still a work in progress and the path is not truncated properly yet (the parts that are in a model file are not omitted) the test I included does not pass. I will fix it as soon as possible, but in the meanwhile any comments are welcome.<br>
<br></div>Thanks,<br>Gábor Horváth<br><div> <br></div></div>