diff --git a/include/llvm/Analysis/LiveVar/ValueSet.h b/include/llvm/Analysis/LiveVar/ValueSet.h index 048d8df4c55..0c0aefad206 100644 --- a/include/llvm/Analysis/LiveVar/ValueSet.h +++ b/include/llvm/Analysis/LiveVar/ValueSet.h @@ -10,7 +10,7 @@ struct RAV { // Register Allocator Value const Value *V; RAV(const Value *v) : V(v) {} }; -ostream &operator<<(ostream &out, RAV Val); +std::ostream &operator<<(std::ostream &out, RAV Val); typedef std::set ValueSet; diff --git a/include/llvm/CodeGen/ValueSet.h b/include/llvm/CodeGen/ValueSet.h index 048d8df4c55..0c0aefad206 100644 --- a/include/llvm/CodeGen/ValueSet.h +++ b/include/llvm/CodeGen/ValueSet.h @@ -10,7 +10,7 @@ struct RAV { // Register Allocator Value const Value *V; RAV(const Value *v) : V(v) {} }; -ostream &operator<<(ostream &out, RAV Val); +std::ostream &operator<<(std::ostream &out, RAV Val); typedef std::set ValueSet; diff --git a/lib/Analysis/LiveVar/BBLiveVar.cpp b/lib/Analysis/LiveVar/BBLiveVar.cpp index 1468301dfce..c6b8a3b8f2c 100644 --- a/lib/Analysis/LiveVar/BBLiveVar.cpp +++ b/lib/Analysis/LiveVar/BBLiveVar.cpp @@ -10,6 +10,7 @@ #include "llvm/BasicBlock.h" #include "llvm/Support/CFG.h" #include "Support/SetOperations.h" +#include /// BROKEN: Should not include sparc stuff directly into here #include "../../Target/Sparc/SparcInternals.h" // Only for PHI defn diff --git a/lib/Analysis/LiveVar/ValueSet.cpp b/lib/Analysis/LiveVar/ValueSet.cpp index 88dd25a0331..ec1d7808efd 100644 --- a/lib/Analysis/LiveVar/ValueSet.cpp +++ b/lib/Analysis/LiveVar/ValueSet.cpp @@ -5,7 +5,7 @@ #include "llvm/ConstantVals.h" #include -ostream &operator<<(ostream &O, RAV V) { // func to print a Value +std::ostream &operator<<(std::ostream &O, RAV V) { // func to print a Value const Value *v = V.V; if (v->hasName()) return O << v << "(" << v->getName() << ") "; diff --git a/lib/Target/SparcV9/LiveVar/BBLiveVar.cpp b/lib/Target/SparcV9/LiveVar/BBLiveVar.cpp index 1468301dfce..c6b8a3b8f2c 100644 --- a/lib/Target/SparcV9/LiveVar/BBLiveVar.cpp +++ b/lib/Target/SparcV9/LiveVar/BBLiveVar.cpp @@ -10,6 +10,7 @@ #include "llvm/BasicBlock.h" #include "llvm/Support/CFG.h" #include "Support/SetOperations.h" +#include /// BROKEN: Should not include sparc stuff directly into here #include "../../Target/Sparc/SparcInternals.h" // Only for PHI defn diff --git a/lib/Target/SparcV9/LiveVar/ValueSet.cpp b/lib/Target/SparcV9/LiveVar/ValueSet.cpp index 88dd25a0331..ec1d7808efd 100644 --- a/lib/Target/SparcV9/LiveVar/ValueSet.cpp +++ b/lib/Target/SparcV9/LiveVar/ValueSet.cpp @@ -5,7 +5,7 @@ #include "llvm/ConstantVals.h" #include -ostream &operator<<(ostream &O, RAV V) { // func to print a Value +std::ostream &operator<<(std::ostream &O, RAV V) { // func to print a Value const Value *v = V.V; if (v->hasName()) return O << v << "(" << v->getName() << ") "; diff --git a/lib/VMCore/Verifier.cpp b/lib/VMCore/Verifier.cpp index 18c3c33b08e..a7f5369a608 100644 --- a/lib/VMCore/Verifier.cpp +++ b/lib/VMCore/Verifier.cpp @@ -64,7 +64,7 @@ static long ValidTypes[Type::FirstDerivedTyID] = { // failed. This provides a nice place to put a breakpoint if you want to see // why something is not correct. // -static inline void CheckFailed(const char *Cond, const string &Message, +static inline void CheckFailed(const char *Cond, const std::string &Message, const Value *V1 = 0, const Value *V2 = 0) { std::cerr << Message << "\n"; if (V1) std::cerr << V1 << "\n"; @@ -100,14 +100,14 @@ static bool verifyInstruction(const Instruction *I) { // Check that PHI nodes look ok if (const PHINode *PN = dyn_cast(I)) { - vector Preds(pred_begin(I->getParent()), - pred_end(I->getParent())); + std::vector Preds(pred_begin(I->getParent()), + pred_end(I->getParent())); // Loop over all of the incoming values, make sure that there are // predecessors for each one... // for (unsigned i = 0, e = PN->getNumIncomingValues(); i != e; ++i) { const BasicBlock *BB = PN->getIncomingBlock(i); - vector::iterator PI = + std::vector::iterator PI = find(Preds.begin(), Preds.end(), BB); Assert2(PI != Preds.end(), "PHI node has entry for basic block that" " is not a predecessor!", PN, BB); @@ -115,8 +115,8 @@ static bool verifyInstruction(const Instruction *I) { } // There should be no entries left in the predecessor list... - for (vector::iterator I = Preds.begin(), E = Preds.end(); - I != E; ++I) + for (std::vector::iterator I = Preds.begin(), + E = Preds.end(); I != E; ++I) Assert2(0, "PHI node does not have entry for a predecessor basic block!", PN, *I); }