<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jan 12, 2015 at 5:44 PM, Chandler Carruth <span dir="ltr"><<a href="mailto:chandlerc@gmail.com" target="_blank">chandlerc@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: chandlerc<br>
Date: Mon Jan 12 19:44:56 2015<br>
New Revision: 225750<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=225750&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=225750&view=rev</a><br>
Log:<br>
[PM] Fix another place where I was using an overly generic T&& for the<br>
IR unit to directly use IRUnitT& for now.<br>
<br>
Modified:<br>
    llvm/trunk/include/llvm/IR/PassManager.h<br>
<br>
Modified: llvm/trunk/include/llvm/IR/PassManager.h<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/IR/PassManager.h?rev=225750&r1=225749&r2=225750&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/IR/PassManager.h?rev=225750&r1=225749&r2=225750&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/include/llvm/IR/PassManager.h (original)<br>
+++ llvm/trunk/include/llvm/IR/PassManager.h Mon Jan 12 19:44:56 2015<br>
@@ -828,7 +828,7 @@ template <typename AnalysisT> struct Inv<br>
 /// analysis passes to be re-run to produce fresh results if any are needed.<br>
 struct InvalidateAllAnalysesPass {<br>
   /// \brief Run this pass over some unit of IR.<br>
-  template <typename T> PreservedAnalyses run(T &&Arg) {<br>
+  template <typename IRUnitT> PreservedAnalyses run(IRUnitT &Arg) {<br></blockquote><div><br>Since this isn't a virtual function you're implementing, you could add 'const' here without breaking any contracts (it's compatible with callers passing non-const, but helps (only slightly) indicate that this isn't modifying.<br><br>Arguably, I would imagine, all Analyses should take a const ref to the IRUnit?<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
     return PreservedAnalyses::none();<br>
   }<br>
<br>
<br>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
</blockquote></div><br></div></div>