aboutsummaryrefslogtreecommitdiffstats
path: root/lib/VMCore/AsmWriter.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-01-20 22:54:45 +0000
committerChris Lattner <sabre@nondot.org>2002-01-20 22:54:45 +0000
commit697954c15da58bd8b186dbafdedd8b06db770201 (patch)
treee119a71f09b5c2513c8c270161ae2a858c6f3b96 /lib/VMCore/AsmWriter.cpp
parent13c4659220bc78a0a3529f4d9e57546e898088e3 (diff)
downloadexternal_llvm-697954c15da58bd8b186dbafdedd8b06db770201.zip
external_llvm-697954c15da58bd8b186dbafdedd8b06db770201.tar.gz
external_llvm-697954c15da58bd8b186dbafdedd8b06db770201.tar.bz2
Changes to build successfully with GCC 3.02
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1503 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/AsmWriter.cpp')
-rw-r--r--lib/VMCore/AsmWriter.cpp16
1 files changed, 10 insertions, 6 deletions
diff --git a/lib/VMCore/AsmWriter.cpp b/lib/VMCore/AsmWriter.cpp
index 2b3a1c4..c218c0f 100644
--- a/lib/VMCore/AsmWriter.cpp
+++ b/lib/VMCore/AsmWriter.cpp
@@ -26,6 +26,10 @@
#include "Support/STLExtras.h"
#include <algorithm>
#include <map>
+using std::string;
+using std::map;
+using std::vector;
+using std::ostream;
static const Module *getModuleFromVal(const Value *V) {
if (const MethodArgument *MA =dyn_cast<const MethodArgument>(V))
@@ -112,7 +116,7 @@ static void fillTypeNameTable(const Module *M,
const Type *Ty = cast<const Type>(I->second);
if (!isa<PointerType>(Ty) ||
!cast<PointerType>(Ty)->getElementType()->isPrimitiveType())
- TypeNames.insert(make_pair(Ty, "%"+I->first));
+ TypeNames.insert(std::make_pair(Ty, "%"+I->first));
}
}
}
@@ -215,7 +219,7 @@ static ostream &printTypeInt(ostream &Out, const Type *Ty,
//
vector<const Type *> TypeStack;
string TypeName = calcTypeName(Ty, TypeStack, TypeNames);
- TypeNames.insert(make_pair(Ty, TypeName)); // Cache type name for later use
+ TypeNames.insert(std::make_pair(Ty, TypeName));//Cache type name for later use
return Out << TypeName;
}
@@ -331,7 +335,7 @@ void AssemblyWriter::printGlobal(const GlobalVariable *GV) {
writeOperand(GV->getInitializer(), false, false);
printInfoComment(GV);
- Out << endl;
+ Out << "\n";
}
@@ -348,7 +352,7 @@ void AssemblyWriter::printSymbolTable(const SymbolTable &ST) {
if (const Constant *CPV = dyn_cast<const Constant>(V)) {
printConstant(CPV);
} else if (const Type *Ty = dyn_cast<const Type>(V)) {
- Out << "\t%" << I->first << " = type " << Ty->getDescription() << endl;
+ Out << "\t%" << I->first << " = type " << Ty->getDescription() << "\n";
}
}
}
@@ -378,7 +382,7 @@ void AssemblyWriter::printConstant(const Constant *CPV) {
else Out << "<badref>";
}
- Out << endl;
+ Out << "\n";
}
// printMethod - Print all aspects of a method.
@@ -614,7 +618,7 @@ void AssemblyWriter::printInstruction(const Instruction *I) {
}
printInfoComment(I);
- Out << endl;
+ Out << "\n";
}