<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>On Sep 20, 2010, at 10:05 PM, Marcin Świderski wrote:</div><div><br class="Apple-interchange-newline"><blockquote type="cite"><div class="gmail_quote">Added comments.</div></blockquote><div><br></div>Thanks Marcin.  The contents of the patch look good to me.</div><div><br></div><div><blockquote type="cite"><div class="gmail_quote"><br></div><div class="gmail_quote">I thought about tests myself but don't really know how should we go about them? I mean that for now destructors will probably be off by default. How to print CFG using the driver? How to set up testing the output?</div></blockquote><div><br></div><div>The CFG can be printed from the command line thusly:</div><div><br></div><div>$ clang -cc1 -analyze -cfg-dump <file.cpp></div><div><br></div><div>we can then check the output using FileCheck.  A good analogous test is plist-output.m, which tests the plist output of the analyzer that is currently used for rendering paths in Xcode (and potentially other clients).</div><div><br></div><blockquote type="cite">
<div class="gmail_quote"><br></div><div class="gmail_quote">W dniu 21 września 2010 03:24 użytkownik Ted Kremenek <span dir="ltr"><<a href="mailto:kremenek@apple.com">kremenek@apple.com</a>></span> napisał:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Looks great!<br>
<br>
Please add doxygen comments about CFGInitializer and CFGAutomaticObjDtor respectively.  We should get in the habit of documenting such core classes in the static analyzer.<br>
<br>
We also should probably add a FileCheck-based test to test/Analysis that tests CFG printing (particularly these new pieces), since it has broken in the past.  Now that we're adding new CFGElements, now seems like a good time to start testing this.<br>

<div><div></div><div class="h5"><br>
On Sep 20, 2010, at 4:42 PM, Marcin Świderski wrote:<br>
<br>
> This patch:<br>
> - defines interfaces for CFGInitializer and CFGAutomaticObjDtor,<br>
> - adds support for above classes to print_elem function (renamed print_stmt)<br>
><br>
> I've extended StmtPrinterHelper to print locations of VarDecls for destructors.<br>
><br>
> Please aprove for commit,<br>
><br>
> Marcin<br>
</div></div>> <cfg-print-elem.patch><br>
<br>
</blockquote></div><br>
<span><cfg-print-elem.patch></span></blockquote></div><br></body></html>