<div dir="ltr">The patch <a href="https://reviews.llvm.org/D26452">https://reviews.llvm.org/D26452</a> implements testing for output made with -ast-print, it fixes problems which this commit addressed (file declare_simd_ast_print.cpp) and tests them.</div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature" data-smartmail="gmail_signature">Thanks,<br>--Serge<br></div></div>
<br><div class="gmail_quote">2016-11-02 23:39 GMT+07:00 Richard Smith <span dir="ltr"><<a href="mailto:richard@metafoo.co.uk" target="_blank">richard@metafoo.co.uk</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">Test?</div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On 30 Oct 2016 10:20 pm, "Serge Pavlov via cfe-commits" <<a href="mailto:cfe-commits@lists.llvm.org" target="_blank">cfe-commits@lists.llvm.org</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: sepavloff<br>
Date: Mon Oct 31 00:11:12 2016<br>
New Revision: 285543<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=285543&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-pr<wbr>oject?rev=285543&view=rev</a><br>
Log:<br>
Make output of ast-print closer to C++ code<br>
<br>
Put semicolon after non-defining method declaration and a class<br>
specialization body.<br>
<br>
Modified:<br>
    cfe/trunk/lib/AST/DeclPrinter.<wbr>cpp<br>
<br>
Modified: cfe/trunk/lib/AST/DeclPrinter.<wbr>cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/DeclPrinter.cpp?rev=285543&r1=285542&r2=285543&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-pr<wbr>oject/cfe/trunk/lib/AST/DeclPr<wbr>inter.cpp?rev=285543&r1=285542<wbr>&r2=285543&view=diff</a><br>
==============================<wbr>==============================<wbr>==================<br>
--- cfe/trunk/lib/AST/DeclPrinter.<wbr>cpp (original)<br>
+++ cfe/trunk/lib/AST/DeclPrinter.<wbr>cpp Mon Oct 31 00:11:12 2016<br>
@@ -337,10 +337,9 @@ void DeclPrinter::VisitDeclContext(<wbr>DeclC<br>
     const char *Terminator = nullptr;<br>
     if (isa<OMPThreadPrivateDecl>(*D) || isa<OMPDeclareReductionDecl>(*<wbr>D))<br>
       Terminator = nullptr;<br>
-    else if (isa<FunctionDecl>(*D) &&<br>
-             cast<FunctionDecl>(*D)->isThi<wbr>sDeclarationADefinition())<br>
+    else if (isa<FunctionDecl>(*D) && cast<FunctionDecl>(*D)->hasBod<wbr>y())<br>
       Terminator = nullptr;<br>
-    else if (isa<ObjCMethodDecl>(*D) && cast<ObjCMethodDecl>(*D)->getB<wbr>ody())<br>
+    else if (isa<ObjCMethodDecl>(*D) && cast<ObjCMethodDecl>(*D)->hasB<wbr>ody())<br>
       Terminator = nullptr;<br>
     else if (isa<NamespaceDecl>(*D) || isa<LinkageSpecDecl>(*D) ||<br>
              isa<ObjCImplementationDecl>(*D<wbr>) ||<br>
@@ -984,7 +983,7 @@ void DeclPrinter::VisitClassTemplat<wbr>eDecl<br>
     for (auto *I : D->specializations()) {<br>
       PrintTemplateParameters(Param<wbr>s, &I->getTemplateArgs());<br>
       Visit(I);<br>
-      Out << '\n';<br>
+      Out << ";\n";<br>
     }<br>
   }<br>
<br>
<br>
<br>
______________________________<wbr>_________________<br>
cfe-commits mailing list<br>
<a href="mailto:cfe-commits@lists.llvm.org" target="_blank">cfe-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/cfe-commits</a><br>
</blockquote></div></div>
</div></div></blockquote></div><br></div>