[cfe-commits] r92305 - /cfe/trunk/lib/Analysis/LiveVariables.cpp

Zhongxing Xu xuzhongxing at gmail.com
Tue Dec 29 22:38:20 PST 2009


Author: zhongxingxu
Date: Wed Dec 30 00:38:20 2009
New Revision: 92305

URL: http://llvm.org/viewvc/llvm-project?rev=92305&view=rev
Log:
Simplify code by using an equivalent template class.

Modified:
    cfe/trunk/lib/Analysis/LiveVariables.cpp

Modified: cfe/trunk/lib/Analysis/LiveVariables.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Analysis/LiveVariables.cpp?rev=92305&r1=92304&r2=92305&view=diff

==============================================================================
--- cfe/trunk/lib/Analysis/LiveVariables.cpp (original)
+++ cfe/trunk/lib/Analysis/LiveVariables.cpp Wed Dec 30 00:38:20 2009
@@ -301,17 +301,8 @@
 //===----------------------------------------------------------------------===//
 
 namespace {
-
-struct Merge {
-  typedef StmtDeclBitVector_Types::ValTy ValTy;
-
-  void operator()(ValTy& Dst, const ValTy& Src) {
-    Dst.OrDeclBits(Src);
-    Dst.OrBlkExprBits(Src);
-  }
-};
-
-typedef DataflowSolver<LiveVariables, TransferFuncs, Merge> Solver;
+  typedef StmtDeclBitVector_Types::Union Merge;
+  typedef DataflowSolver<LiveVariables, TransferFuncs, Merge> Solver;
 } // end anonymous namespace
 
 //===----------------------------------------------------------------------===//





More information about the cfe-commits mailing list