diff options
author | Chris Lattner <sabre@nondot.org> | 2003-11-21 20:23:48 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2003-11-21 20:23:48 +0000 |
commit | 31f8499e83dc4dccbb57ea7e76d1fd49b7010d0c (patch) | |
tree | 7311a395f4b05b01958cb55d80ba5432ad7f32c3 /lib/VMCore/AsmWriter.cpp | |
parent | 23e1492bb1e67f740c232abe985ec6d609ffae63 (diff) |
Finegrainify namespacification
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10131 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/AsmWriter.cpp')
-rw-r--r-- | lib/VMCore/AsmWriter.cpp | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/lib/VMCore/AsmWriter.cpp b/lib/VMCore/AsmWriter.cpp index 1823412755..671864972b 100644 --- a/lib/VMCore/AsmWriter.cpp +++ b/lib/VMCore/AsmWriter.cpp @@ -32,8 +32,7 @@ #include "Support/StringExtras.h" #include "Support/STLExtras.h" #include <algorithm> - -namespace llvm { +using namespace llvm; static RegisterPass<PrintModulePass> X("printm", "Print module to stderr",PassInfo::Analysis|PassInfo::Optimization); @@ -233,8 +232,8 @@ static std::ostream &printTypeInt(std::ostream &Out, const Type *Ty, // type, iff there is an entry in the modules symbol table for the specified // type or one of it's component types. This is slower than a simple x << Type; // -std::ostream &WriteTypeSymbolic(std::ostream &Out, const Type *Ty, - const Module *M) { +std::ostream &llvm::WriteTypeSymbolic(std::ostream &Out, const Type *Ty, + const Module *M) { Out << " "; // If they want us to print out a type, attempt to make it symbolic if there @@ -447,7 +446,8 @@ static void WriteAsOperandInternal(std::ostream &Out, const Value *V, // ostream. This can be useful when you just want to print int %reg126, not the // whole instruction that generated it. // -std::ostream &WriteAsOperand(std::ostream &Out, const Value *V, bool PrintType, +std::ostream &llvm::WriteAsOperand(std::ostream &Out, const Value *V, + bool PrintType, bool PrintName, const Module *Context) { std::map<const Type *, std::string> TypeNames; if (Context == 0) Context = getModuleFromVal(V); @@ -465,7 +465,7 @@ std::ostream &WriteAsOperand(std::ostream &Out, const Value *V, bool PrintType, return Out; } - +namespace llvm { class AssemblyWriter { std::ostream &Out; @@ -520,7 +520,7 @@ private : // which slot it occupies. void printInfoComment(const Value &V); }; - +} // end of anonymous namespace // printTypeAtLeastOneLevel - Print out one level of the possibly complex type // without considering any symbolic types that we may have equal to it. @@ -1063,5 +1063,3 @@ CachedWriter &CachedWriter::operator<<(const Value *V) { } return *this; } - -} // End llvm namespace |