<html><head></head><body bgcolor="#FFFFFF"><div>It calls the DIFile ctor, but that doesn't have side effects other than creating the class. :-) Thr same object is created a few lines below anyway. <br><br>-bw</div><div><br>On Jun 12, 2012, at 1:21 AM, Chandler Carruth <<a href="mailto:chandlerc@google.com">chandlerc@google.com</a>> wrote:<br><br></div><div></div><blockquote type="cite"><div><div class="gmail_quote">On Mon, Jun 11, 2012 at 11:53 PM, Bill Wendling <span dir="ltr"><<a href="mailto:isanbard@gmail.com" target="_blank">isanbard@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Author: void<br>
Date: Tue Jun 12 01:53:25 2012<br>
New Revision: 158353<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=158353&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=158353&view=rev</a><br>
Log:<br>
Remove unused variable.<br></blockquote><div><br></div><div>Is this really without a side-effect? Routines called "getOrCreateFoo" tend to leave me with the expectation that calling them did something somewhere else, so I'm a bit surprised this was just dropped on the floor... </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Modified:<br>
    cfe/trunk/lib/CodeGen/CGDebugInfo.cpp<br>
<br>
Modified: cfe/trunk/lib/CodeGen/CGDebugInfo.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGDebugInfo.cpp?rev=158353&r1=158352&r2=158353&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGDebugInfo.cpp?rev=158353&r1=158352&r2=158353&view=diff</a><br>

==============================================================================<br>
--- cfe/trunk/lib/CodeGen/CGDebugInfo.cpp (original)<br>
+++ cfe/trunk/lib/CodeGen/CGDebugInfo.cpp Tue Jun 12 01:53:25 2012<br>
@@ -1565,7 +1565,6 @@<br>
<br>
 /// CreateEnumType - get enumeration type.<br>
 llvm::DIType CGDebugInfo::CreateEnumType(const EnumDecl *ED) {<br>
-  llvm::DIFile Unit = getOrCreateFile(ED->getLocation());<br>
   SmallVector<llvm::Value *, 16> Enumerators;<br>
<br>
   // Create DIEnumerator elements for each enumerator.<br>
<br>
<br>
_______________________________________________<br>
cfe-commits mailing list<br>
<a href="mailto:cfe-commits@cs.uiuc.edu">cfe-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits</a><br>
</blockquote></div><br>
</div></blockquote></body></html>