Thanks for noticing this. I will fix this and commit if there are no other issues.<br><br><div class="gmail_quote">W dniu 30 września 2010 08:25 użytkownik Zhongxing Xu <span dir="ltr"><<a href="mailto:xuzhongxing@gmail.com">xuzhongxing@gmail.com</a>></span> napisał:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi Marcin,<br><br>Overall the patch looks good. But one problem:<br><br>@@ -126,7 +130,8 @@<br> idx::TranslationUnit *TU) {<br>
AnalysisContext *&AC = Contexts[D];<br>
if (!AC)<br>- AC = new AnalysisContext(D, TU, UseUnoptimizedCFG);<br>+ AC = new AnalysisContext(D, TU, UseUnoptimizedCFG, AddImplicitDtors,<br>+ AddInitializers);<br><br>Notice that the fourth parameter is bool addehedges = false. We could set it to false for now. In the future we would add an option for it, too. <br>
<br>You could spot this bug by actually running clang with the patch on a test case:<br><br>$ clang -cc1 -analyze -cfg-view -cfg-add-implicit-dtors scope.cpp<br><br>And see no effect with the new option.<br></blockquote>
<div><br></div><div>I did test the patch some other way and it appeared to work properly. Sometimes tests can be broken though...</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br>And for each patch, you can run 'make test' to ensure it does not break regression tests.<br>
<br></blockquote><div>Yes, I do it all the time.</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><br><div class="gmail_quote">2010/9/30 Marcin Świderski <span dir="ltr"><<a href="mailto:marcin.sfider@gmail.com" target="_blank">marcin.sfider@gmail.com</a>></span><div>
<div></div><div class="h5"><br><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204, 204, 204);padding-left:1ex">
Patch adds two new command line arguments:<div>-cfg-add-implicit-dtors - sets CFG::BuildOptions::AddImplicitDtors for AnalysisCosumer to true</div>-cfg-add-initializers - sets CFG::BuildOptions::AddInitializers for AnalysisCosumer to true<div>
<br></div><div>Please approve for commit.</div><div><br></div><font color="#888888"><div>Marcin</div>
</font></blockquote></div></div></div><br>
</blockquote></div><br>