Do not use BasicBlock::*_iterator, just use *_iterator itself.
authorChris Lattner <sabre@nondot.org>
Wed, 24 Sep 2003 22:06:25 +0000 (22:06 +0000)
committerChris Lattner <sabre@nondot.org>
Wed, 24 Sep 2003 22:06:25 +0000 (22:06 +0000)
Isn't updating copy and pasted code a joy

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8702 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Instrumentation/ProfilePaths/CombineBranch.cpp
lib/Transforms/Instrumentation/ProfilePaths/InstLoops.cpp
lib/Transforms/Instrumentation/ProfilePaths/ProfilePaths.cpp
lib/Transforms/Instrumentation/ProfilePaths/RetracePath.cpp

index f6f3016acd5146b7de28b32f0b6eb75e04a844df..16f98e7d08a6df5ae958f60a55e7742d72e07281 100644 (file)
@@ -57,8 +57,7 @@ void CombineBranches::getBackEdgesVisit(BasicBlock *u,
   time++;
   d[u]=time;
 
-  for(BasicBlock::succ_iterator vl = succ_begin(u), 
-       ve = succ_end(u); vl != ve; ++vl){
+  for (succ_iterator vl = succ_begin(u), ve = succ_end(u); vl != ve; ++vl){
     
     BasicBlock *BB = *vl;
 
index 6802c4fd96c3c62344c149084d91b242734d8e74..74209b7ea5d074fe8f7250ca3de011a4702100ca 100644 (file)
@@ -58,8 +58,7 @@ void InstLoops::getBackEdgesVisit(BasicBlock *u,
   time++;
   d[u]=time;
 
-  for(BasicBlock::succ_iterator vl = succ_begin(u), 
-       ve = succ_end(u); vl != ve; ++vl){
+  for(succ_iterator vl = succ_begin(u), ve = succ_end(u); vl != ve; ++vl){
     BasicBlock *BB = *vl;
 
     if(color[BB]!=GREY && color[BB]!=BLACK){
index aa46048ae0343b9d27f53816b247b3f156ac1e69..962996247ceea7ea227e276afc82a156af54d223 100644 (file)
@@ -98,8 +98,7 @@ bool ProfilePaths::runOnFunction(Function &F){
     Node *nd=findBB(nodes, BB);
     assert(nd && "No node for this edge!");
 
-    for(BasicBlock::succ_iterator s=succ_begin(BB), se=succ_end(BB); 
-       s!=se; ++s){
+    for(succ_iterator s=succ_begin(BB), se=succ_end(BB); s!=se; ++s){
       Node *nd2=findBB(nodes,*s);
       assert(nd2 && "No node for this edge!");
       Edge ed(nd,nd2,0);
index 805250fd9a07b4e1621271e1a1cc98298b0fe107..0f8382319a3655e02c5132b5fae25e00d98432d7 100644 (file)
@@ -216,8 +216,7 @@ void getBBtrace(vector<BasicBlock *> &vBB, int pathNo, Function *M){//,
       Node *nd=findBB(nodes, BB);
       assert(nd && "No node for this edge!");
       
-      for(BasicBlock::succ_iterator s=succ_begin(BB), se=succ_end(BB); 
-          s!=se; ++s){
+      for(succ_iterator s=succ_begin(BB), se=succ_end(BB); s!=se; ++s){
         
         if(triggerBBs[*s] == 9){
           //if(!pathReg[M]){ //Get the path register for this!