[llvm-commits] [llvm] r93364 -	/llvm/trunk/include/llvm/Support/CFG.h
    Tobias Grosser 
    grosser at fim.uni-passau.de
       
    Wed Jan 13 14:21:43 PST 2010
    
    
  
Author: grosser
Date: Wed Jan 13 16:21:43 2010
New Revision: 93364
URL: http://llvm.org/viewvc/llvm-project?rev=93364&view=rev
Log:
Add getSource() to SuccIterator
Get the source BB of an iterator.
Modified:
    llvm/trunk/include/llvm/Support/CFG.h
Modified: llvm/trunk/include/llvm/Support/CFG.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/CFG.h?rev=93364&r1=93363&r2=93364&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/CFG.h (original)
+++ llvm/trunk/include/llvm/Support/CFG.h Wed Jan 13 16:21:43 2010
@@ -189,6 +189,11 @@
   //  tmp += offset;
   //  return tmp.operator*();
   // }
+
+  /// Get the source BB of this iterator.
+  inline BB_ *getSource() {
+      return Term->getParent();
+  }
 };
 
 typedef SuccIterator<TerminatorInst*, BasicBlock> succ_iterator;
    
    
More information about the llvm-commits
mailing list