[DynInst_API:] [PATCH 2/2] fix more namespace pollution


Date: Sat, 23 Apr 2016 15:57:08 -0400
From: Peter Foley <pefoley2@xxxxxxxxxxx>
Subject: [DynInst_API:] [PATCH 2/2] fix more namespace pollution
Remove implicit inclusion of namespace std from more files.

Signed-off-by: Peter Foley <pefoley2@xxxxxxxxxxx>
---
 dataflowAPI/h/liveness.h                           |  9 ++-
 dataflowAPI/src/liveness.C                         | 66 ++++++++++-----------
 dyninstAPI/src/BPatch.C                            | 36 ++++++------
 dyninstAPI/src/BPatch_addressSpace.C               |  2 +-
 dyninstAPI/src/BPatch_basicBlockLoop.C             |  4 +-
 dyninstAPI/src/BPatch_edge.C                       |  4 +-
 dyninstAPI/src/BPatch_function.C                   | 10 ++--
 dyninstAPI/src/BPatch_module.C                     | 12 ++--
 dyninstAPI/src/BPatch_object.C                     |  2 +-
 dyninstAPI/src/BPatch_process.C                    | 68 +++++++++++-----------
 dyninstAPI/src/BPatch_snippet.C                    | 12 ++--
 dyninstAPI/src/BPatch_type.C                       | 10 ++--
 dyninstAPI/src/MemoryEmulator/memEmulator.C        | 18 +++---
 .../src/MemoryEmulator/memEmulatorTransformer.C    |  4 +-
 dyninstAPI/src/MemoryEmulator/memEmulatorWidget.C  | 14 ++---
 dyninstAPI/src/Parsing.C                           |  2 +-
 dyninstAPI/src/Relocation/CFG/RelocBlock.C         | 18 +++---
 dyninstAPI/src/Relocation/CFG/RelocTarget.h        | 12 ++--
 dyninstAPI/src/Relocation/CodeBuffer.C             | 16 ++---
 dyninstAPI/src/Relocation/CodeMover.C              | 12 ++--
 dyninstAPI/src/Relocation/CodeTracker.C            | 14 ++---
 dyninstAPI/src/Relocation/Springboard.C            | 48 +++++++--------
 dyninstAPI/src/Relocation/Transformers/Defensive.C |  4 +-
 .../src/Relocation/Transformers/Instrumenter.C     |  6 +-
 .../src/Relocation/Transformers/Modification.C     |  6 +-
 .../src/Relocation/Transformers/Movement-adhoc.C   |  4 +-
 .../Relocation/Transformers/Movement-analysis.C    | 14 ++---
 dyninstAPI/src/Relocation/Widgets/CFPatch.C        | 10 ++--
 dyninstAPI/src/Relocation/Widgets/CFWidget-ppc.C   | 10 ++--
 dyninstAPI/src/Relocation/Widgets/CFWidget-x86.C   | 10 ++--
 dyninstAPI/src/Relocation/Widgets/CFWidget.C       |  8 +--
 dyninstAPI/src/Relocation/Widgets/InsnWidget.C     |  8 +--
 dyninstAPI/src/Relocation/Widgets/PCWidget.C       |  4 +-
 dyninstAPI/src/Relocation/Widgets/RelDataWidget.C  |  4 +-
 dyninstAPI/src/Relocation/Widgets/StackModWidget.C |  4 +-
 dyninstAPI/src/StackMod/StackModChecker.C          | 28 ++++-----
 dyninstAPI/src/StackMod/StackModChecker.h          |  2 +-
 dyninstAPI/src/addressSpace.C                      | 28 ++++-----
 dyninstAPI/src/ast.C                               | 38 ++++++------
 dyninstAPI/src/binaryEdit.C                        | 12 ++--
 dyninstAPI/src/codegen-x86.C                       |  2 +-
 dyninstAPI/src/codegen.C                           |  8 +--
 dyninstAPI/src/dynProcess.C                        | 54 ++++++++---------
 dyninstAPI/src/emit-x86.C                          |  4 +-
 dyninstAPI/src/function.C                          | 12 ++--
 dyninstAPI/src/function.h                          | 14 ++---
 dyninstAPI/src/hybridAnalysis.h                    |  2 +-
 dyninstAPI/src/hybridCallbacks.C                   |  8 +--
 dyninstAPI/src/hybridInstrumentation.C             | 10 ++--
 dyninstAPI/src/hybridOverwrites.C                  |  8 +--
 dyninstAPI/src/image.C                             | 12 ++--
 dyninstAPI/src/image.h                             | 58 +++++++++---------
 dyninstAPI/src/inst.C                              |  2 +-
 dyninstAPI/src/instPoint.C                         |  8 +--
 dyninstAPI/src/mapped_module.C                     |  4 +-
 dyninstAPI/src/mapped_module.h                     |  4 +-
 dyninstAPI/src/mapped_object.C                     | 64 ++++++++++----------
 dyninstAPI/src/mapped_object.h                     | 24 ++++----
 dyninstAPI/src/parse-cfg.h                         |  6 +-
 dyninstAPI/src/parse-x86.C                         |  6 +-
 dyninstAPI/src/pcEventHandler.C                    |  4 +-
 dyninstAPI/src/pcEventMuxer.C                      |  6 +-
 dyninstAPI/src/unix.C                              |  8 +--
 dyninstAPI/src/variable.C                          |  2 +-
 parseAPI/h/GraphAdapter.h                          |  1 -
 parseAPI/h/Location.h                              |  1 -
 symtabAPI/h/Archive.h                              | 32 +++++-----
 symtabAPI/src/Archive-elf.C                        |  8 +--
 symtabAPI/src/Archive.C                            | 20 +++----
 69 files changed, 490 insertions(+), 495 deletions(-)

diff --git a/dataflowAPI/h/liveness.h b/dataflowAPI/h/liveness.h
index acd798a..a6ef46e 100644
--- a/dataflowAPI/h/liveness.h
+++ b/dataflowAPI/h/liveness.h
@@ -44,7 +44,6 @@
 #include <set>
 
 
-using namespace std;
 using namespace Dyninst;
 using namespace Dyninst::InstructionAPI;
 
@@ -53,9 +52,9 @@ struct livenessData{
 };
 
 class DATAFLOW_EXPORT LivenessAnalyzer{
-	map<ParseAPI::Block*, livenessData> blockLiveInfo;
-	map<ParseAPI::Function*, bool> liveFuncCalculated;
-        map<ParseAPI::Function*, bitArray> funcRegsDefined;
+	std::map<ParseAPI::Block*, livenessData> blockLiveInfo;
+	std::map<ParseAPI::Function*, bool> liveFuncCalculated;
+        std::map<ParseAPI::Function*, bitArray> funcRegsDefined;
 	InstructionCache cachedLivenessInfo;
 
 	const bitArray& getLivenessIn(ParseAPI::Block *block);
@@ -84,7 +83,7 @@ public:
 	bool query(ParseAPI::Location loc, Type type, OutputIterator outIter){
 		bitArray liveRegs;
 		if (query(loc,type, liveRegs)){
-			for (map<MachRegister,int>::const_iterator iter = abi->getIndexMap()->begin(); iter != abi->getIndexMap()->end(); ++iter)
+			for (std::map<MachRegister,int>::const_iterator iter = abi->getIndexMap()->begin(); iter != abi->getIndexMap()->end(); ++iter)
 				if (liveRegs[iter->second]){
 					outIter = iter->first;
 					++outIter;
diff --git a/dataflowAPI/src/liveness.C b/dataflowAPI/src/liveness.C
index 0cd89a2..2e619b5 100644
--- a/dataflowAPI/src/liveness.C
+++ b/dataflowAPI/src/liveness.C
@@ -62,7 +62,7 @@ int LivenessAnalyzer::getIndex(MachRegister machReg){
 
 const bitArray& LivenessAnalyzer::getLivenessIn(Block *block) {
     // Calculate if it hasn't been done already
-   liveness_cerr << "Getting liveness for block " << hex << block->start() << dec << endl;
+   liveness_cerr << "Getting liveness for block " << std::hex << block->start() << std::dec << std::endl;
     assert(blockLiveInfo.find(block) != blockLiveInfo.end());
     livenessData& data = blockLiveInfo[block];
     assert(data.in.size());
@@ -77,15 +77,15 @@ void LivenessAnalyzer::processEdgeLiveness(Edge* e, livenessData& data, Block* b
   // Is this correct?
   if (e->type() == CATCH) return;
   if (e->sinkEdge()) {
-    liveness_cerr << "Sink edge from " << hex << block->start() << dec << endl;
+    liveness_cerr << "Sink edge from " << std::hex << block->start() << std::dec << std::endl;
     data.out |= allRegsDefined;
     return;
   }
   
   // TODO: multiple entry functions and you?
   data.out |= getLivenessIn(e->trg());
-  liveness_cerr << "Accumulating from block " << hex << (e->trg())->start() << dec << endl;
-  liveness_cerr << data.out << endl;
+  liveness_cerr << "Accumulating from block " << std::hex << (e->trg())->start() << std::dec << std::endl;
+  liveness_cerr << data.out << std::endl;
 }
 
 
@@ -102,7 +102,7 @@ const bitArray& LivenessAnalyzer::getLivenessOut(Block *block, bitArray &allRegs
     // OUT(X) = UNION(IN(Y)) for all successors Y of X
     const Block::edgelist & target_edges = block -> targets();
 
-    liveness_cerr << "getLivenessOut for block [" << hex << block->start() << "," << block->end() << "]" << dec << endl;
+    liveness_cerr << "getLivenessOut for block [" << std::hex << block->start() << "," << block->end() << "]" << std::dec << std::endl;
     
 
     std::for_each(boost::make_filter_iterator(epred, target_edges.begin(), target_edges.end()),
@@ -114,8 +114,8 @@ const bitArray& LivenessAnalyzer::getLivenessOut(Block *block, bitArray &allRegs
 			      block,
 			      boost::ref(allRegsDefined)));
     
-    liveness_cerr << " Returning liveness for out " << endl;
-    liveness_cerr << "  " << data.out << endl;
+    liveness_cerr << " Returning liveness for out " << std::endl;
+    liveness_cerr << "  " << data.out << std::endl;
 
 
     return data.out;
@@ -154,25 +154,25 @@ void LivenessAnalyzer::summarizeBlockLivenessInfo(Function* func, Block *block,
       
      liveness_printf("%s[%d] After instruction at address 0x%lx:\n",
                      FILE__, __LINE__, current);
-     liveness_cerr << "        " << regs1 << endl;
-     liveness_cerr << "        " << regs2 << endl;
-     liveness_cerr << "        " << regs3 << endl;
-     liveness_cerr << "Read    " << curInsnRW.read << endl;
-     liveness_cerr << "Written " << curInsnRW.written << endl;
-     liveness_cerr << "Used    " << data.use << endl;
-     liveness_cerr << "Defined " << data.def << endl;
+     liveness_cerr << "        " << regs1 << std::endl;
+     liveness_cerr << "        " << regs2 << std::endl;
+     liveness_cerr << "        " << regs3 << std::endl;
+     liveness_cerr << "Read    " << curInsnRW.read << std::endl;
+     liveness_cerr << "Written " << curInsnRW.written << std::endl;
+     liveness_cerr << "Used    " << data.use << std::endl;
+     liveness_cerr << "Defined " << data.def << std::endl;
 
       current += curInsn->size();
       curInsn = decoder.decode();
    }
 
    liveness_printf("%s[%d] Liveness summary for block:\n", FILE__, __LINE__);
-   liveness_cerr << "     " << regs1 << endl;
-   liveness_cerr << "     " << regs2 << endl;
-   liveness_cerr << "     " << regs3 << endl;
-   liveness_cerr << "Used " << data.in << endl;
-   liveness_cerr << "Def  " << data.def << endl;
-   liveness_cerr << "Use  " << data.use << endl;
+   liveness_cerr << "     " << regs1 << std::endl;
+   liveness_cerr << "     " << regs2 << std::endl;
+   liveness_cerr << "     " << regs3 << std::endl;
+   liveness_cerr << "Used " << data.in << std::endl;
+   liveness_cerr << "Def  " << data.def << std::endl;
+   liveness_cerr << "Use  " << data.use << std::endl;
    liveness_printf("%s[%d] --------------------\n---------------------\n", FILE__, __LINE__);
 
    allRegsDefined |= data.def;
@@ -186,7 +186,7 @@ bool LivenessAnalyzer::updateBlockLivenessInfo(Block* block, bitArray &allRegsDe
 {
   bool change = false;
   livenessData &data = blockLiveInfo[block];
-  liveness_cerr << "Updating block info for block " << hex << block->start() << dec << endl;
+  liveness_cerr << "Updating block info for block " << std::hex << block->start() << std::dec << std::endl;
 
   // old_IN = IN(X)
   bitArray oldIn = data.in;
@@ -198,14 +198,14 @@ bool LivenessAnalyzer::updateBlockLivenessInfo(Block* block, bitArray &allRegsDe
   // OUT(X) = UNION(IN(Y)) for all successors Y of X
 
   // IN(X) = USE(X) + (OUT(X) - DEF(X))
-  liveness_cerr << "     " << regs1 << endl;
-  liveness_cerr << "     " << regs2 << endl;
-  liveness_cerr << "     " << regs3 << endl;
-  liveness_cerr << "Out: " << data.out << endl;
-  liveness_cerr << "Def: " << data.def << endl;
-  liveness_cerr << "Use: " << data.use << endl;
+  liveness_cerr << "     " << regs1 << std::endl;
+  liveness_cerr << "     " << regs2 << std::endl;
+  liveness_cerr << "     " << regs3 << std::endl;
+  liveness_cerr << "Out: " << data.out << std::endl;
+  liveness_cerr << "Def: " << data.def << std::endl;
+  liveness_cerr << "Use: " << data.use << std::endl;
   data.in = data.use | (data.out - data.def);
-  liveness_cerr << "In:  " << data.in << endl;
+  liveness_cerr << "In:  " << data.in << std::endl;
   
   // if (old_IN != IN(X)) then change = true
   if (data.in != oldIn)
@@ -395,12 +395,12 @@ bool LivenessAnalyzer::query(Location loc, Type type, bitArray &bitarray) {
 
       liveness_printf("%s[%d] Calculating liveness for iP 0x%lx, insn at 0x%lx\n",
                       FILE__, __LINE__, addr, *current);
-      liveness_cerr << "Pre:    " << working << endl;
+      liveness_cerr << "Pre:    " << working << std::endl;
       working &= (~rwAtCurrent.written);
       working |= rwAtCurrent.read;
-      liveness_cerr << "Post:   " << working << endl;
-      liveness_cerr << "Current read:  " << rwAtCurrent.read << endl;
-      liveness_cerr << "Current Write: " << rwAtCurrent.written << endl;
+      liveness_cerr << "Post:   " << working << std::endl;
+      liveness_cerr << "Current read:  " << rwAtCurrent.read << std::endl;
+      liveness_cerr << "Current Write: " << rwAtCurrent.written << std::endl;
       
       ++current;
    }
@@ -425,7 +425,7 @@ bool LivenessAnalyzer::query(Location loc, Type type, const MachRegister& machRe
 ReadWriteInfo LivenessAnalyzer::calcRWSets(Instruction::Ptr curInsn, Block* blk, Address a)
 {
 
-  liveness_cerr << "calcRWSets for " << curInsn->format() << " @ " << hex << a << dec << endl;
+  liveness_cerr << "calcRWSets for " << curInsn->format() << " @ " << std::hex << a << std::dec << std::endl;
   ReadWriteInfo ret;
   ret.read = abi->getBitArray();
   ret.written = abi->getBitArray();
diff --git a/dyninstAPI/src/BPatch.C b/dyninstAPI/src/BPatch.C
index e43de34..cb5245b 100644
--- a/dyninstAPI/src/BPatch.C
+++ b/dyninstAPI/src/BPatch.C
@@ -163,7 +163,7 @@ BPatch::BPatch()
     APITypes = BPatch_typeCollection::getGlobalTypeCollection();
 
     stdTypes = BPatch_typeCollection::getGlobalTypeCollection();
-    vector<Type *> *sTypes = Symtab::getAllstdTypes();
+    std::vector<Type *> *sTypes = Symtab::getAllstdTypes();
     for(unsigned i=0; i< sTypes->size(); i++)
         stdTypes->addType(new BPatch_type((*sTypes)[i]));
 
@@ -1047,7 +1047,7 @@ void BPatch::unRegisterProcess(int pid, BPatch_process *proc)
 static void buildPath(const char *path, const char **argv,
                       char * &pathToUse,
                       char ** &argvToUse) {
-   ifstream file;
+   std::ifstream file;
    file.open(path);
    if (!file.is_open()) return;
    std::string line;
@@ -1391,10 +1391,10 @@ BPatch_type * BPatch::createEnum( const char * name,
     if (elementNames.size() != elementIds.size()) {
       return NULL;
     }
-    string typeName = name;
-    vector<pair<string, int> *>elements;
+    std::string typeName = name;
+    std::vector<std::pair<std::string, int> *>elements;
     for (unsigned int i=0; i < elementNames.size(); i++) 
-        elements.push_back(new pair<string, int>(elementNames[i], elementIds[i]));
+        elements.push_back(new std::pair<std::string, int>(elementNames[i], elementIds[i]));
     
     Type *typ = typeEnum::create( typeName, elements);
     if (!typ) return NULL;
@@ -1420,10 +1420,10 @@ BPatch_type * BPatch::createEnum( const char * name,
 BPatch_type * BPatch::createEnum( const char * name, 
 				        BPatch_Vector<char *> &elementNames)
 {
-    string typeName = name;
-    vector<pair<string, int> *>elements;
+    std::string typeName = name;
+    std::vector<std::pair<std::string, int> *>elements;
     for (unsigned int i=0; i < elementNames.size(); i++) 
-        elements.push_back(new pair<string, int>(elementNames[i], i));
+        elements.push_back(new std::pair<std::string, int>(elementNames[i], i));
     
     Type *typ = typeEnum::create( typeName, elements);
     if (!typ) return NULL;
@@ -1456,13 +1456,13 @@ BPatch_type * BPatch::createStruct( const char * name,
       return NULL;
    }
    
-   string typeName = name;
-   vector<pair<string, Type *> *> fields;
+   std::string typeName = name;
+   std::vector<std::pair<std::string, Type *> *> fields;
    for(i=0; i<fieldNames.size(); i++)
    {
       if(!fieldTypes[i])
          return NULL;
-      fields.push_back(new pair<string, Type *> (fieldNames[i], fieldTypes[i]->getSymtabType()));
+      fields.push_back(new std::pair<std::string, Type *> (fieldNames[i], fieldTypes[i]->getSymtabType()));
    }	
    
    Type *typ = typeStruct::create(typeName, fields);
@@ -1496,13 +1496,13 @@ BPatch_type * BPatch::createUnion( const char * name,
       return NULL;
     }
 
-    string typeName = name;
-    vector<pair<string, Type *> *> fields;
+    std::string typeName = name;
+    std::vector<std::pair<std::string, Type *> *> fields;
     for(i=0; i<fieldNames.size(); i++)
     {
         if(!fieldTypes[i])
 	    return NULL;
-        fields.push_back(new pair<string, Type *> (fieldNames[i], fieldTypes[i]->getSymtabType()));
+        fields.push_back(new std::pair<std::string, Type *> (fieldNames[i], fieldTypes[i]->getSymtabType()));
     }	
     
     Type *typ = typeUnion::create(typeName, fields);
@@ -1533,7 +1533,7 @@ BPatch_type * BPatch::createArray( const char * name, BPatch_type * ptr,
     if (!ptr) 
         return NULL;
         
-    string typeName = name;
+    std::string typeName = name;
     Type *typ = typeArray::create(typeName, ptr->getSymtabType(), low, hi);
     if (!typ) return NULL;
     
@@ -1560,7 +1560,7 @@ BPatch_type * BPatch::createPointer(const char * name, BPatch_type * ptr,
     if(!ptr)
         return NULL;
     
-    string typeName = name;
+    std::string typeName = name;
     Type *typ = typePointer::create(typeName, ptr->getSymtabType());
     if (!typ) return NULL;
     
@@ -1585,7 +1585,7 @@ BPatch_type * BPatch::createScalar( const char * name, int size)
 {
     BPatch_type * newType;
     
-    string typeName = name;
+    std::string typeName = name;
     Type *typ = typeScalar::create(typeName, size);
     if (!typ) return NULL;
     
@@ -1611,7 +1611,7 @@ BPatch_type * BPatch::createTypedef( const char * name, BPatch_type * ptr)
     if(!ptr)
         return NULL;
     
-    string typeName = name;
+    std::string typeName = name;
     Type *typ = typeTypedef::create(typeName, ptr->getSymtabType());
     if (!typ) return NULL;
     
diff --git a/dyninstAPI/src/BPatch_addressSpace.C b/dyninstAPI/src/BPatch_addressSpace.C
index d269724..a7aee23 100644
--- a/dyninstAPI/src/BPatch_addressSpace.C
+++ b/dyninstAPI/src/BPatch_addressSpace.C
@@ -900,7 +900,7 @@ BPatchSnippetHandle *BPatch_addressSpace::insertSnippet(const BPatch_snippet &ex
       BPatch_function *f;
       for (unsigned i=0; i<points.size(); i++) {
          f = points[i]->getFunction();
-         const string sname = f->func->prettyName();
+         const std::string sname = f->func->prettyName();
          inst_printf("[%s:%u] - %d. Insert instrumentation at function %s, "
                "address %p, when %d, order %d\n",
                FILE__, __LINE__, i,
diff --git a/dyninstAPI/src/BPatch_basicBlockLoop.C b/dyninstAPI/src/BPatch_basicBlockLoop.C
index f07ba79..ce10f8e 100644
--- a/dyninstAPI/src/BPatch_basicBlockLoop.C
+++ b/dyninstAPI/src/BPatch_basicBlockLoop.C
@@ -245,12 +245,12 @@ std::set<BPatch_variableExpr*>* BPatch_basicBlockLoop::getLoopIterators(){
 std::string BPatch_basicBlockLoop::format() const {
    std::stringstream ret;
    
-   ret << hex << "(Loop " << this << ": ";
+   ret << std::hex << "(Loop " << this << ": ";
    for (std::set<BPatch_basicBlock *>::iterator iter = basicBlocks.begin();
         iter != basicBlocks.end(); ++iter) {
       ret << (*iter)->getStartAddress() << ", ";
    }
-   ret << ")" << dec << endl;
+   ret << ")" << std::dec << endl;
 
    return ret.str();
 }
diff --git a/dyninstAPI/src/BPatch_edge.C b/dyninstAPI/src/BPatch_edge.C
index 29fc5c1..dec24da 100644
--- a/dyninstAPI/src/BPatch_edge.C
+++ b/dyninstAPI/src/BPatch_edge.C
@@ -43,10 +43,10 @@
 
 using namespace Dyninst;
 
-string 
+std::string 
 edge_type_string(BPatch_edgeType t)
 { 
-    string ts = "Invalid Edge Type";
+    std::string ts = "Invalid Edge Type";
     switch (t) {
     case CondJumpTaken: { ts = "CondJumpTaken"; break; }
     case CondJumpNottaken: { ts = "CondJumpNottaken"; break; }
diff --git a/dyninstAPI/src/BPatch_function.C b/dyninstAPI/src/BPatch_function.C
index 1d3fe87..78d166a 100644
--- a/dyninstAPI/src/BPatch_function.C
+++ b/dyninstAPI/src/BPatch_function.C
@@ -239,7 +239,7 @@ bool BPatch_function::getTypedNames(std::vector<std::string> &names) {
 char *BPatch_function::getName(char *s, int len)
 {
     assert(func);
-    string name = func->prettyName();
+    std::string name = func->prettyName();
     strncpy(s, name.c_str(), len);
     return s;
 }
@@ -265,7 +265,7 @@ const char *BPatch_function::getNameDPCL()
 char *BPatch_function::getMangledName(char *s, int len)
 {
   assert(func);
-  string mangledname = func->symTabName();
+  std::string mangledname = func->symTabName();
   strncpy(s, mangledname.c_str(), len);
   return s;
 }
@@ -283,7 +283,7 @@ char *BPatch_function::getMangledName(char *s, int len)
 char *BPatch_function::getTypedName(char *s, int len)
 {
   assert(func);
-  string typedname = func->typedName();
+  std::string typedname = func->typedName();
   strncpy(s, typedname.c_str(), len);
   return s;
 }
@@ -929,13 +929,13 @@ char *BPatch_function::getModuleName(char *name, int maxLen) {
 BPatch_variableExpr *BPatch_function::getFunctionRef() 
 {
   Address remoteAddress = (Address)getBaseAddr();
-  string fname = func->prettyName();
+  std::string fname = func->prettyName();
 
   //  Need to figure out the type for this effective function pointer,
   //  of the form <return type> (*)(<arg1 type>, ... , <argn type>)
   
   //  Note:  getParams allocates the vector
-  string typestr;
+  std::string typestr;
   if(retType) {
       typestr += retType->getName();
   } else {
diff --git a/dyninstAPI/src/BPatch_module.C b/dyninstAPI/src/BPatch_module.C
index d08e51d..bca2209 100644
--- a/dyninstAPI/src/BPatch_module.C
+++ b/dyninstAPI/src/BPatch_module.C
@@ -101,7 +101,7 @@ char *BPatch_module::getName(char *buffer, int length)
    if (!mod)
       return NULL;
 
-   string str = mod->fileName();
+   std::string str = mod->fileName();
 
    strncpy(buffer, str.c_str(), length);
 
@@ -123,7 +123,7 @@ char *BPatch_module::getFullName(char *buffer, int length)
 {
    if (!mod)
       return NULL;
-   string str = mod->fullName();
+   std::string str = mod->fullName();
 
    strncpy(buffer, str.c_str(), length);
 
@@ -272,7 +272,7 @@ bool BPatch_module::parseTypesIfNecessary()
 		moduleTypes->addType(type);
 	}
 
-	vector<pair<string, Type *> > *globalVars = mod->pmod()->mod()->getAllGlobalVars();
+	vector<std::pair<std::string, Type *> > *globalVars = mod->pmod()->mod()->getAllGlobalVars();
 
 	if (!globalVars)
 		return false;
@@ -467,7 +467,7 @@ BPatch_module::findFunction(const char *name,
          for (auto piter = func->pretty_names_begin(); 
 	      piter != func->pretty_names_end();
 	      ++piter) {
-	   const string &pName = *piter;
+	   const std::string &pName = *piter;
             int err;     
             if (0 == (err = regexec(&comp_pat, pName.c_str(), 1, NULL, 0 ))){
                if (func->isInstrumentable() || incUninstrumentable) {
@@ -484,7 +484,7 @@ BPatch_module::findFunction(const char *name,
          for (auto miter = func->symtab_names_begin(); 
 	      miter != func->symtab_names_end();
 	      ++miter) {
-	   const string &mName = *miter;
+	   const std::string &mName = *miter;
             int err;
 
             if (0 == (err = regexec(&comp_pat, mName.c_str(), 1, NULL, 0 ))){
@@ -530,7 +530,7 @@ BPatch_module::findFunctionByAddress(void *addr, BPatch_Vector<BPatch_function *
    if (!isValid()) {
       if (notify_on_failure) {
          using namespace std;
-         string msg = string("Module is not valid: ") + string(mod->fileName());
+         std::string msg = std::string("Module is not valid: ") + std::string(mod->fileName());
          BPatch_reportError(BPatchSerious, 100, msg.c_str());
       }
       return NULL;
diff --git a/dyninstAPI/src/BPatch_object.C b/dyninstAPI/src/BPatch_object.C
index fc22b3c..8ba0686 100644
--- a/dyninstAPI/src/BPatch_object.C
+++ b/dyninstAPI/src/BPatch_object.C
@@ -171,7 +171,7 @@ bool BPatch_object::findPoints(Dyninst::Address addr,
 std::string BPatch_object::Region::format() {
    std::stringstream ret;
    
-   ret << "[" << hex << base << "," << (base + size) << ","
+   ret << "[" << std::hex << base << "," << (base + size) << ","
        << ((type == CODE) ? "CODE" : "DATA") << "]";
    return ret.str();
 }
diff --git a/dyninstAPI/src/BPatch_process.C b/dyninstAPI/src/BPatch_process.C
index f5f92c7..0353dc4 100644
--- a/dyninstAPI/src/BPatch_process.C
+++ b/dyninstAPI/src/BPatch_process.C
@@ -1324,25 +1324,25 @@ bool BPatch_process::hideDebugger()
     bool retval = llproc->hideDebugger();
 
     // disable API calls //
-    vector<pair<BPatch_function *,BPatch_function *> > disabledFuncs;
+    std::vector<std::pair<BPatch_function *,BPatch_function *> > disabledFuncs;
     BPatch_module *user = image->findModule("user32.dll",true);
     BPatch_module *kern = image->findModule("*kernel32.dll",true);
 
     if (user) {
         // BlockInput
         using namespace SymtabAPI;
-        vector<BPatch_function*> funcs;
+        std::vector<BPatch_function*> funcs;
         user->findFunction(
             "BlockInput",
             funcs, false, false, false, true);
         assert (funcs.size());
         BPatch_module *rtlib = this->image->findOrCreateModule(
             (*llproc->runtime_lib.begin())->getModules().front());
-        vector<BPatch_function*> repfuncs;
+        std::vector<BPatch_function*> repfuncs;
         rtlib->findFunction("DYNINST_FakeBlockInput", repfuncs, false);
         assert(!repfuncs.empty());
         replaceFunction(*funcs[0],*repfuncs[0]);
-        disabledFuncs.push_back(pair<BPatch_function*,BPatch_function*>(
+        disabledFuncs.push_back(std::pair<BPatch_function*,BPatch_function*>(
                                 funcs[0],repfuncs[0]));
     }
 
@@ -1350,36 +1350,36 @@ bool BPatch_process::hideDebugger()
         // SuspendThread
         // KEVINTODO: condition the function replacement on its thread ID parameter matching a Dyninst thread
         using namespace SymtabAPI;
-        vector<BPatch_function*> funcs;
+        std::vector<BPatch_function*> funcs;
         kern->findFunction(
             "SuspendThread",
             funcs, false, false, false, true);
         assert (funcs.size());
         BPatch_module *rtlib = this->image->findOrCreateModule(
             (*llproc->runtime_lib.begin())->getModules().front());
-        vector<BPatch_function*> repfuncs;
+        std::vector<BPatch_function*> repfuncs;
         rtlib->findFunction("DYNINST_FakeSuspendThread", repfuncs, false);
         assert(!repfuncs.empty());
         replaceFunction(*funcs[0],*repfuncs[0]);
-        disabledFuncs.push_back(pair<BPatch_function*,BPatch_function*>(
+        disabledFuncs.push_back(std::pair<BPatch_function*,BPatch_function*>(
                                 funcs[0],repfuncs[0]));
     }
 
     if (kern) {
         // getTickCount
         using namespace SymtabAPI;
-        vector<BPatch_function*> funcs;
+        std::vector<BPatch_function*> funcs;
         kern->findFunction(
             "GetTickCount",
             funcs, false, false, false, true);
         if (!funcs.empty()) {
 			BPatch_module *rtlib = this->image->findOrCreateModule(
 				(*llproc->runtime_lib.begin())->getModules().front());
-			vector<BPatch_function*> repfuncs;
+			std::vector<BPatch_function*> repfuncs;
 			rtlib->findFunction("DYNINST_FakeTickCount", repfuncs, false);
 			assert(!repfuncs.empty());
 			replaceFunction(*funcs[0],*repfuncs[0]);
-			disabledFuncs.push_back(pair<BPatch_function*,BPatch_function*>(
+			disabledFuncs.push_back(std::pair<BPatch_function*,BPatch_function*>(
 									funcs[0],repfuncs[0]));
 		}
     }
@@ -1387,54 +1387,54 @@ bool BPatch_process::hideDebugger()
     if (kern) {
         // getSystemTime
         using namespace SymtabAPI;
-        vector<BPatch_function*> funcs;
+        std::vector<BPatch_function*> funcs;
         kern->findFunction(
             "GetSystemTime",
             funcs, false, false, false, true);
         assert (!funcs.empty());
         BPatch_module *rtlib = this->image->findOrCreateModule(
             (*llproc->runtime_lib.begin())->getModules().front());
-        vector<BPatch_function*> repfuncs;
+        std::vector<BPatch_function*> repfuncs;
         rtlib->findFunction("DYNINST_FakeGetSystemTime", repfuncs, false);
         assert(!repfuncs.empty());
         replaceFunction(*funcs[0],*repfuncs[0]);
-        disabledFuncs.push_back(pair<BPatch_function*,BPatch_function*>(
+        disabledFuncs.push_back(std::pair<BPatch_function*,BPatch_function*>(
                                 funcs[0],repfuncs[0]));
     }
 
     if (kern) {
         // CheckRemoteDebuggerPresent
-        vector<BPatch_function*> funcs;
+        std::vector<BPatch_function*> funcs;
         kern->findFunction(
             "CheckRemoteDebuggerPresent",
             funcs, false, false, true);
         assert (funcs.size());
         BPatch_module *rtlib = this->image->findOrCreateModule(
             (*llproc->runtime_lib.begin())->getModules().front());
-        vector<BPatch_function*> repfuncs;
+        std::vector<BPatch_function*> repfuncs;
         rtlib->findFunction("DYNINST_FakeCheckRemoteDebuggerPresent", repfuncs, false);
         assert(!repfuncs.empty());
         replaceFunction(*funcs[0],*repfuncs[0]);
-        disabledFuncs.push_back(pair<BPatch_function*,BPatch_function*>(
+        disabledFuncs.push_back(std::pair<BPatch_function*,BPatch_function*>(
                                 funcs[0],repfuncs[0]));
     }
 
     if (kern && user) {
         // OutputDebugStringA
-        vector<BPatch_function*> funcs;
+        std::vector<BPatch_function*> funcs;
         kern->findFunction("OutputDebugStringA",
             funcs, false, false, true);
         assert(funcs.size());
-        vector<BPatch_function*> sle_funcs;
+        std::vector<BPatch_function*> sle_funcs;
         user->findFunction("SetLastErrorEx", sle_funcs,
                            false, false, true, true);
         assert(!sle_funcs.empty());
-        vector<BPatch_snippet*> args;
+        std::vector<BPatch_snippet*> args;
         BPatch_constExpr lasterr(1);
         args.push_back(&lasterr);
         args.push_back(&lasterr); // need a second parameter, but it goes unused by windows
         BPatch_funcCallExpr callSLE (*(sle_funcs[0]), args);
-        vector<BPatch_point*> *exitPoints = sle_funcs[0]->findPoint(BPatch_exit);
+        std::vector<BPatch_point*> *exitPoints = sle_funcs[0]->findPoint(BPatch_exit);
         beginInsertionSet();
         for (unsigned i=0; i < exitPoints->size(); i++) {
             insertSnippet( callSLE, *((*exitPoints)[i]) );
@@ -1570,11 +1570,11 @@ void BPatch_process::overwriteAnalysisUpdate
     // create stub edge set which is: all edges such that:
     //     e->trg() in owBBIs and
     //     while e->src() in delBlocks choose stub from among e->src()->sources()
-    std::map<func_instance*,vector<edgeStub> > stubs =
+    std::map<func_instance*,std::vector<edgeStub> > stubs =
        llproc->getStubs(owBBIs,delBlocks,deadFuncs);
 
     // get stubs for dead funcs
-    map<Address,vector<block_instance*> > deadFuncCallers;
+    map<Address,std::vector<block_instance*> > deadFuncCallers;
     for(std::list<func_instance*>::iterator fit = deadFuncs.begin();
         fit != deadFuncs.end();
         fit++)
@@ -1586,10 +1586,10 @@ void BPatch_process::overwriteAnalysisUpdate
           // but mark the caller point as unresolved so we'll re-parse
           // if we actually call into the garbage func
           Address funcAddr = (*fit)->addr();
-          vector<block_instance*>::iterator sit = deadFuncCallers[funcAddr].begin();
+          std::vector<block_instance*>::iterator sit = deadFuncCallers[funcAddr].begin();
           for ( ; sit != deadFuncCallers[funcAddr].end(); sit++) {
              (*sit)->llb()->setUnresolvedCF(true);
-             vector<func_instance*> cfuncs;
+             std::vector<func_instance*> cfuncs;
              (*sit)->getFuncs(std::back_inserter(cfuncs));
              for (unsigned i=0; i < cfuncs.size(); i++) {
                 cfuncs[i]->ifunc()->setPrevBlocksUnresolvedCF(0); // force rebuild of unresolved list
@@ -1612,13 +1612,13 @@ void BPatch_process::overwriteAnalysisUpdate
     }
     
     // delete delBlocks and set new function entry points, if necessary
-    vector<PatchBlock*> delVector;
+    std::vector<PatchBlock*> delVector;
     for(set<block_instance*>::reverse_iterator bit = delBlocks.rbegin(); 
         bit != delBlocks.rend();
         bit++)
     {
         mal_printf("Deleting block [%lx %lx)\n", (*bit)->start(),(*bit)->end());
-        deadBlocks.push_back(pair<Address,int>((*bit)->start(),(*bit)->size()));
+        deadBlocks.push_back(std::pair<Address,int>((*bit)->start(),(*bit)->size()));
         delVector.push_back(*bit);
     }
     if (!delVector.empty() && ! PatchAPI::PatchModifier::remove(delVector,true)) {
@@ -1635,7 +1635,7 @@ void BPatch_process::overwriteAnalysisUpdate
         const PatchFunction::Blockset& deadBs = (*fit)->blocks();
         PatchFunction::Blockset::const_iterator bIter= deadBs.begin();
         for (; bIter != deadBs.end(); bIter++) {
-            deadBlocks.push_back(pair<Address,int>((*bIter)->start(),
+            deadBlocks.push_back(std::pair<Address,int>((*bIter)->start(),
                                                    (*bIter)->size()));
         }
     }
@@ -1648,9 +1648,9 @@ void BPatch_process::overwriteAnalysisUpdate
         fit++)
     {
         const PatchBlock::edgelist & srcs = (*fit)->entry()->sources();
-        vector<PatchEdge*> srcVec; // can't operate off edgelist, since we'll be deleting edges
+        std::vector<PatchEdge*> srcVec; // can't operate off edgelist, since we'll be deleting edges
         srcVec.insert(srcVec.end(), srcs.begin(), srcs.end());
-        for (vector<PatchEdge*>::const_iterator sit = srcVec.begin();
+        for (std::vector<PatchEdge*>::const_iterator sit = srcVec.begin();
              sit != srcVec.end();
              sit++)
         {
@@ -1667,12 +1667,12 @@ void BPatch_process::overwriteAnalysisUpdate
 
 
     // set up data structures for re-parsing dead functions from stubs
-    map<mapped_object*,vector<edgeStub> > dfstubs;
-    for (map<Address, vector<block_instance*> >::iterator sit = deadFuncCallers.begin();
+    map<mapped_object*,std::vector<edgeStub> > dfstubs;
+    for (map<Address, std::vector<block_instance*> >::iterator sit = deadFuncCallers.begin();
          sit != deadFuncCallers.end();
          sit++)
     {
-       for (vector<block_instance*>::iterator bit = sit->second.begin();
+       for (std::vector<block_instance*>::iterator bit = sit->second.begin();
             bit != sit->second.end();
             bit++) 
        {
@@ -1684,12 +1684,12 @@ void BPatch_process::overwriteAnalysisUpdate
    }
 
     // re-parse the functions
-    for (map<mapped_object*,vector<edgeStub> >::iterator mit= dfstubs.begin();
+    for (map<mapped_object*,std::vector<edgeStub> >::iterator mit= dfstubs.begin();
          mit != dfstubs.end(); mit++)
     {
         mit->first->setCodeBytesUpdated(false);
         if (mit->first->parseNewEdges(mit->second)) {
-            // add functions to output vector
+            // add functions to output std::vector
             for (unsigned fidx=0; fidx < mit->second.size(); fidx++) {
                BPatch_function *bpfunc = findFunctionByEntry(mit->second[fidx].trg);
                if (bpfunc) {
diff --git a/dyninstAPI/src/BPatch_snippet.C b/dyninstAPI/src/BPatch_snippet.C
index b530012..cb61499 100644
--- a/dyninstAPI/src/BPatch_snippet.C
+++ b/dyninstAPI/src/BPatch_snippet.C
@@ -341,7 +341,7 @@ AstNodePtr generateFieldRef(const BPatch_snippet &lOperand,
                 return AstNodePtr();
         }
 
-        vector<Field *> *fields;
+        std::vector<Field *> *fields;
         Field *field = NULL;
 
         // check that the name of the right operand is a field of the left operand
@@ -1166,7 +1166,7 @@ BPatch_variableExpr::BPatch_variableExpr(BPatch_addressSpace *in_addSpace,
    type(typ),
    intvar(NULL)
 {
-   vector<AstNodePtr> variableASTs;
+   std::vector<AstNodePtr> variableASTs;
    AstNodePtr variableAst;
 
    if (!type)
@@ -1246,9 +1246,9 @@ BPatch_variableExpr::BPatch_variableExpr(BPatch_addressSpace *in_addSpace,
                 type = BPatch::bpatch->type_Untyped;
 
         //Address baseAddr =  scp->getFunction()->lowlevel_func()->obj()->codeBase();
-        vector<AstNodePtr> variableASTs;
-        vector<pair<Offset, Offset> > *ranges = new vector<pair<Offset, Offset> >;
-        vector<Dyninst::VariableLocation> &locs = lv->getSymtabVar()->getLocationLists();
+        std::vector<AstNodePtr> variableASTs;
+        std::vector<std::pair<Offset, Offset> > *ranges = new std::vector<std::pair<Offset, Offset> >;
+        std::vector<Dyninst::VariableLocation> &locs = lv->getSymtabVar()->getLocationLists();
         for (unsigned i=0; i<locs.size(); i++)
         {
                 AstNodePtr variableAst;
@@ -1299,7 +1299,7 @@ BPatch_variableExpr::BPatch_variableExpr(BPatch_addressSpace *in_addSpace,
 					hi = locs[i].hiPC;
 				}
 
-                ranges->push_back(pair<Address, Address>(low, hi));
+                ranges->push_back(std::pair<Address, Address>(low, hi));
         }
         ast_wrapper = AstNodePtr(AstNode::variableNode(variableASTs, ranges));
         //    ast_wrapper = variableAst;
diff --git a/dyninstAPI/src/BPatch_type.C b/dyninstAPI/src/BPatch_type.C
index 7eb708c..45a2c17 100644
--- a/dyninstAPI/src/BPatch_type.C
+++ b/dyninstAPI/src/BPatch_type.C
@@ -231,7 +231,7 @@ BPatch_Vector<BPatch_field *> *BPatch_type::getComponents() const{
         return NULL;	
     BPatch_Vector<BPatch_field *> *components = new BPatch_Vector<BPatch_field *>();
     if(fieldlisttype) {
-        vector<Field *> *comps = fieldlisttype->getComponents();
+        std::vector<Field *> *comps = fieldlisttype->getComponents();
     	if(!comps){
          delete components;
          return NULL;
@@ -243,7 +243,7 @@ BPatch_Vector<BPatch_field *> *BPatch_type::getComponents() const{
 
     if (enumtype) 
 	{
-        vector<pair<string, int> > &constants = enumtype->getConstants();
+        std::vector<std::pair<std::string, int> > &constants = enumtype->getConstants();
 	    for (unsigned i = 0; i < constants.size(); i++)
 		{
 	        Field *fld = new Field(constants[i].first.c_str(), NULL);
@@ -497,7 +497,7 @@ BPatch_localVar::BPatch_localVar(localVar *lVar_) : lVar(lVar_)
 
 	type->incrRefCount();
 
-        vector<Dyninst::VariableLocation> &locs = lVar_->getLocationLists();
+        std::vector<Dyninst::VariableLocation> &locs = lVar_->getLocationLists();
 
     if (!locs.size())
        storageClass = BPatch_storageFrameOffset;
@@ -556,7 +556,7 @@ int BPatch_localVar::getLineNum() {
 //TODO?? - get the first frame offset
 long BPatch_localVar::getFrameOffset() {
 
-   vector<Dyninst::VariableLocation> &locs = lVar->getLocationLists();
+   std::vector<Dyninst::VariableLocation> &locs = lVar->getLocationLists();
 
    if (locs.empty())
       return -1;
@@ -566,7 +566,7 @@ long BPatch_localVar::getFrameOffset() {
 
 int BPatch_localVar::getRegister() {
 
-    vector<Dyninst::VariableLocation> &locs = lVar->getLocationLists();
+    std::vector<Dyninst::VariableLocation> &locs = lVar->getLocationLists();
 
     if (!locs.size())
         return -1;
diff --git a/dyninstAPI/src/MemoryEmulator/memEmulator.C b/dyninstAPI/src/MemoryEmulator/memEmulator.C
index 15ddfd9..371a821 100644
--- a/dyninstAPI/src/MemoryEmulator/memEmulator.C
+++ b/dyninstAPI/src/MemoryEmulator/memEmulator.C
@@ -310,7 +310,7 @@ void MemoryEmulator::removeRegion(Address addr, unsigned size) {
 	Address lb = 0, ub = 0;
 	unsigned long shiftVal;
 
-	cerr << "MemoryEmulator: removing region " << hex << addr << " : " << size << dec << endl;
+	cerr << "MemoryEmulator: removing region " << std::hex << addr << " : " << size << std::dec << endl;
 
    //debug();
    //cerr << endl;
@@ -455,7 +455,7 @@ void MemoryEmulator::addSpringboard(Region *reg, Address offset, int size)
     }
     std::map<Address, int> &smap = s_iter->second;
 
-    springboard_cerr << "Inserting SB [" << hex << offset << "," << offset + size << "]" << dec << endl;
+    springboard_cerr << "Inserting SB [" << std::hex << offset << "," << offset + size << "]" << std::dec << endl;
 
     std::map<Address, int>::iterator iter = smap.find(offset);
     if (iter == smap.end()) {
@@ -465,12 +465,12 @@ void MemoryEmulator::addSpringboard(Region *reg, Address offset, int size)
         smap[offset] = size;
     }
     // Otherwise keep the current value
-    springboard_cerr << "\t New value: " << hex << offset << " -> " << smap[offset] + offset << dec << endl;
+    springboard_cerr << "\t New value: " << std::hex << offset << " -> " << smap[offset] + offset << std::dec << endl;
 }
 
 void MemoryEmulator::removeSpringboards(func_instance * func) 
 {
-   malware_cerr << "untracking springboards from deadfunc " << hex << func->addr() << dec << endl;
+   malware_cerr << "untracking springboards from deadfunc " << std::hex << func->addr() << std::dec << endl;
 
    const PatchFunction::Blockset & blocks = func->blocks();
    PatchFunction::Blockset::const_iterator bit = blocks.begin();
@@ -481,8 +481,8 @@ void MemoryEmulator::removeSpringboards(func_instance * func)
 
 void MemoryEmulator::removeSpringboards(const block_instance *bbi) 
 {
-    malware_cerr << "  untracking springboards from deadblock [" << hex 
-         << bbi->start() << " " << bbi->end() << ")" << dec <<endl;
+    malware_cerr << "  untracking springboards from deadblock [" << std::hex 
+         << bbi->start() << " " << bbi->end() << ")" << std::dec <<endl;
     SymtabAPI::Region * reg = 
        ((ParseAPI::SymtabCodeRegion*)bbi->llb()->region())->symRegion();
     springboards_[reg].erase(bbi->llb()->start() - reg->getMemOffset());
@@ -498,7 +498,7 @@ void  MemoryEmulator::debug() const {
 	cerr << "\t Forward map: " << endl;
 	for (std::vector<MemoryMapTree::Entry>::iterator iter = elements.begin(); iter != elements.end(); ++iter)
 	{
-		cerr << "\t\t " << hex << "[" << iter->first.first << "," << iter->first.second << "]: " << iter->second << dec << endl;
+		cerr << "\t\t " << std::hex << "[" << iter->first.first << "," << iter->first.second << "]: " << iter->second << std::dec << endl;
 #if 0 // debug output
       if (iter->first.first == 0x40d000) {
          Address val;
@@ -507,7 +507,7 @@ void  MemoryEmulator::debug() const {
          Address width = aS_->getAddressWidth();
          for (Address idx=0; idx < 0x40; idx+=width) {
             aS_->readDataSpace((void*)(addr+idx), width, &val, true);
-            cerr << hex << " " << 0x40d84b + idx << "[" << addr+idx << "]:  ";
+            cerr << std::hex << " " << 0x40d84b + idx << "[" << addr+idx << "]:  ";
             fprintf(stderr,"%2x",((unsigned char*)&val)[3]);
             fprintf(stderr,"%2x",((unsigned char*)&val)[2]);
             fprintf(stderr,"%2x",((unsigned char*)&val)[1]);
@@ -521,7 +521,7 @@ void  MemoryEmulator::debug() const {
 	reverseMemoryMap_.elements(elements);
 	for (std::vector<MemoryMapTree::Entry>::iterator iter = elements.begin(); iter != elements.end(); ++iter)
 	{
-		cerr << "\t\t " << hex << "[" << iter->first.first << "," << iter->first.second << "]: " << iter->second << dec << endl;
+		cerr << "\t\t " << std::hex << "[" << iter->first.first << "," << iter->first.second << "]: " << iter->second << std::dec << endl;
 	}
 	elements.clear();
 
diff --git a/dyninstAPI/src/MemoryEmulator/memEmulatorTransformer.C b/dyninstAPI/src/MemoryEmulator/memEmulatorTransformer.C
index ef056dc..c6c95ec 100644
--- a/dyninstAPI/src/MemoryEmulator/memEmulatorTransformer.C
+++ b/dyninstAPI/src/MemoryEmulator/memEmulatorTransformer.C
@@ -66,7 +66,7 @@ bool MemEmulatorTransformer::process(RelocBlock *rblock, RelocGraph *rgraph)
      InsnWidget::Ptr reloc = boost::dynamic_pointer_cast<Relocation::InsnWidget>(*e_iter);
      if (!reloc) continue;
 
-    relocation_cerr << "Memory emulation considering addr " << hex << reloc->addr() << dec << endl;
+    relocation_cerr << "Memory emulation considering addr " << std::hex << reloc->addr() << std::dec << endl;
 
     if (BPatch_defensiveMode != func->obj()->hybridMode() || !isSensitive(reloc, func, rblock->block())) {
         relocation_cerr << "\t Not sensitive, skipping" << endl;
@@ -74,7 +74,7 @@ bool MemEmulatorTransformer::process(RelocBlock *rblock, RelocGraph *rgraph)
     }
 
     if (!canRewriteMemInsn(reloc, func)) {
-       malware_cerr << "\tUnable to rewrite memory access at "<< hex << reloc->addr() <<": " << reloc->format() << dec << endl;
+       malware_cerr << "\tUnable to rewrite memory access at "<< std::hex << reloc->addr() <<": " << reloc->format() << std::dec << endl;
        continue;
     }
 
diff --git a/dyninstAPI/src/MemoryEmulator/memEmulatorWidget.C b/dyninstAPI/src/MemoryEmulator/memEmulatorWidget.C
index ab0173a..735993a 100644
--- a/dyninstAPI/src/MemoryEmulator/memEmulatorWidget.C
+++ b/dyninstAPI/src/MemoryEmulator/memEmulatorWidget.C
@@ -145,13 +145,13 @@ bool MemEmulator::generate(const codeGen &templ,
 	if (generateViaModRM(buffer))
 		return true;
 
-	cerr << "Error: failed to emulate memory operation @ " << hex << addr() << dec << ", " << insn()->format() << endl;
+	cerr << "Error: failed to emulate memory operation @ " << std::hex << addr() << std::dec << ", " << insn()->format() << endl;
 	unsigned char *tmp = (unsigned char *)insn()->ptr();
-	cerr << hex << "\t raw: ";
+	cerr << std::hex << "\t raw: ";
 	for (unsigned i = 0; i < insn()->size(); ++i) {
 		cerr << tmp[i];
 	}
-	cerr << dec << endl;
+	cerr << std::dec << endl;
 	assert(0);
 	return false;
 }
@@ -245,7 +245,7 @@ bool MemEmulator::generateEAXMove(unsigned char opcode,
     bool valid; Address target;
     boost::tie(valid, target) = scratch.addrSpace()->getMemEm()->translate(origTarget);
     if (!valid) target = origTarget;
-    //cerr << "Handling mov EAX, [offset]: opcode " << hex << opcode << ", orig dest " << origTarget << " and translated " << target << dec << endl;
+    //cerr << "Handling mov EAX, [offset]: opcode " << std::hex << opcode << ", orig dest " << origTarget << " and translated " << target << std::dec << endl;
     // And emit the insn
     assert(insn_->size() == 5);
     GET_PTR(buf, scratch);
@@ -745,7 +745,7 @@ bool MemEmulator::restoreAllRegistersESI_EDI() {
 }
 
 string MemEmulator::format() const {
-  stringstream ret;
+  std::stringstream ret;
   ret << "MemE(" << insn_->format()
       << "," << std::hex << addr_ << std::dec
       << ")";
@@ -774,7 +774,7 @@ Address MemEmulator::getTranslatorAddr(bool wantShift) {
 
 bool MemEmulatorPatch::apply(codeGen &gen,
                              CodeBuffer *) {
-   relocation_cerr << "MemEmulatorPatch::apply @ " << hex << gen.currAddr() << dec << endl;
+   relocation_cerr << "MemEmulatorPatch::apply @ " << std::hex << gen.currAddr() << std::dec << endl;
    relocation_cerr << "\tSource reg " << source_ << endl;
    assert(!gen.bt());
 
@@ -786,7 +786,7 @@ bool MemEmulatorPatch::apply(codeGen &gen,
 
    // Step 2: call the translator
    Address src = gen.currAddr() + 5;
-   relocation_cerr << "\tCall " << hex << dest_ << ", offset " << dest_ - src << dec << endl;
+   relocation_cerr << "\tCall " << std::hex << dest_ << ", offset " << dest_ - src << std::dec << endl;
    assert(dest_);
    emitCallRel32(dest_ - src, gen);
    if (target_ != REGNUM_EAX) 
diff --git a/dyninstAPI/src/Parsing.C b/dyninstAPI/src/Parsing.C
index fbd8c2d..76475d0 100644
--- a/dyninstAPI/src/Parsing.C
+++ b/dyninstAPI/src/Parsing.C
@@ -150,7 +150,7 @@ DynCFGFactory::mksink(CodeObject *obj, CodeRegion *r) {
 
     record_block_alloc(true);
 
-    ret = new parse_block(obj,r,numeric_limits<Address>::max());
+    ret = new parse_block(obj,r,std::numeric_limits<Address>::max());
     return ret;
 }
 
diff --git a/dyninstAPI/src/Relocation/CFG/RelocBlock.C b/dyninstAPI/src/Relocation/CFG/RelocBlock.C
index 57ee7d6..352eacf 100644
--- a/dyninstAPI/src/Relocation/CFG/RelocBlock.C
+++ b/dyninstAPI/src/Relocation/CFG/RelocBlock.C
@@ -265,13 +265,13 @@ bool RelocBlock::determineSpringboards(PriorityMap &p) {
    if (func_ &&
        func_->entryBlock() == block_) {
      relocation_cerr << "determineSpringboards (entry block): " << func_->symTabName()
-		     << " / " << hex << block_->start() << " is required" << dec << endl;
+		     << " / " << std::hex << block_->start() << " is required" << std::dec << endl;
       p[std::make_pair(block_, func_)] = Required;
       return true;
    }
    if (inEdges_.contains(ParseAPI::INDIRECT)) {
      relocation_cerr << "determineSpringboards (indirect target): " << func_->symTabName()
-		     << " / " << hex << block_->start() << " is required" << dec << endl;
+		     << " / " << std::hex << block_->start() << " is required" << std::dec << endl;
       p[std::make_pair(block_, func_)] = Required;
       return true;
    }
@@ -289,8 +289,8 @@ bool RelocBlock::determineSpringboards(PriorityMap &p) {
      }
       if ((*iter)->src->type() != TargetInt::RelocBlockTarget) {
 	relocation_cerr << "determineSpringboards (non-relocated source): " << func_->symTabName()
-			<< " / " << hex << block_->start() << " is required (type "
-			<< (*iter)->src->type() << ")" << dec << endl;
+			<< " / " << std::hex << block_->start() << " is required (type "
+			<< (*iter)->src->type() << ")" << std::dec << endl;
 	relocation_cerr << "\t" << (*iter)->src->format() << endl;
 	p[std::make_pair(block_, func_)] = Required;
          return true;
@@ -374,9 +374,9 @@ void RelocBlock::preserveBlockGap() {
          block_instance *target = SCAST_EI(*iter)->trg();
          if (target && !(*iter)->sinkEdge()) {
             if (target->start() < block_->end()) {
-               cerr << "Error: source should precede target; edge type " << ParseAPI::format((*iter)->type()) << hex
+               cerr << "Error: source should precede target; edge type " << ParseAPI::format((*iter)->type()) << std::hex
                     << " src[" << block_->start() << " " << block_->end()
-                    << "] trg[" << target->start() << " " << target->end() << dec << "]" << endl;
+                    << "] trg[" << target->start() << " " << target->end() << std::dec << "]" << endl;
                assert(0);
             }
             cfWidget()->setGap(target->start() - block_->end());
@@ -469,7 +469,7 @@ void RelocBlock::determineNecessaryBranches(RelocBlock *successor) {
 
 bool RelocBlock::generate(const codeGen &templ,
 			  CodeBuffer &buffer) {
-   relocation_cerr << "Generating block " << id() << " orig @ " << hex << origAddr() << dec << endl;
+   relocation_cerr << "Generating block " << id() << " orig @ " << std::hex << origAddr() << std::dec << endl;
    relocation_cerr << "\t" << elements_.size() << " elements" << endl; 
    relocation_cerr << "\t At entry, code buffer has size " << buffer.size() << endl;
   
@@ -500,7 +500,7 @@ bool RelocBlock::generate(const codeGen &templ,
 }
 
 std::string RelocBlock::format() const {
-    stringstream ret;
+    std::stringstream ret;
   ret << "RelocBlock(" 
       << func()->obj()->fullName() << ": " << func()->name() << " " 
       << std::hex << origAddr() << std::dec
@@ -571,7 +571,7 @@ bool RelocBlock::finalizeCF() {
          index = (*iter)->trg->origAddr();
       }
       if (debug) {
-         cerr << "Adding destination /w/ index " << index << " and target " << hex << (*iter)->trg->origAddr() << dec << endl;
+         cerr << "Adding destination /w/ index " << index << " and target " << std::hex << (*iter)->trg->origAddr() << std::dec << endl;
       }
       cfWidget_->addDestination(index, (*iter)->trg);
       (*iter)->trg->setNecessary(isNecessary((*iter)->trg, (*iter)->type));
diff --git a/dyninstAPI/src/Relocation/CFG/RelocTarget.h b/dyninstAPI/src/Relocation/CFG/RelocTarget.h
index 2dbb80f..c1911d5 100644
--- a/dyninstAPI/src/Relocation/CFG/RelocTarget.h
+++ b/dyninstAPI/src/Relocation/CFG/RelocTarget.h
@@ -114,8 +114,8 @@ template <>
   
   virtual type_t type() const { return RelocBlockTarget; };
   
-  virtual string format() const { 
-     stringstream ret;
+  virtual std::string format() const { 
+     std::stringstream ret;
      ret << "T{" << t_->id() << "/" << (necessary() ? "+" : "-") << "}";
      return ret.str();
   }
@@ -149,8 +149,8 @@ class Target<block_instance *> : public TargetInt {
 
   Address origAddr() const { return t_->start(); };
   
-  virtual string format() const { 
-    stringstream ret;
+  virtual std::string format() const { 
+    std::stringstream ret;
     ret << "B{" << std::hex << t_->start() << "/" << (necessary() ? "+" : "-") << std::dec << "}";
     return ret.str();
   }
@@ -177,8 +177,8 @@ class Target<Address> : public TargetInt {
 
   Address origAddr() const { return t_; };
 
-  virtual string format() const {
-    stringstream ret;
+  virtual std::string format() const {
+    std::stringstream ret;
     ret << "A{" << std::hex << t_ << "/" << (necessary() ? "+" : "-") <<  std::dec << "}";
     return ret.str();
   }
diff --git a/dyninstAPI/src/Relocation/CodeBuffer.C b/dyninstAPI/src/Relocation/CodeBuffer.C
index f54ad07..e7d0ccf 100644
--- a/dyninstAPI/src/Relocation/CodeBuffer.C
+++ b/dyninstAPI/src/Relocation/CodeBuffer.C
@@ -315,10 +315,10 @@ void CodeBuffer::updateLabel(unsigned id, Address offset, bool &regenerate) {
    if (!l.valid()) return;
 
    //relocation_cerr << "\t Updating label " << id 
-//                   << " -> " << hex << offset << dec << endl;
+//                   << " -> " << std::hex << offset << std::dec << endl;
    if (l.addr != offset) {
-      //relocation_cerr << "\t\t Old value " << hex << labels_[id].addr
-//                      << ", regenerating!" << dec << endl;
+      //relocation_cerr << "\t\t Old value " << std::hex << labels_[id].addr
+//                      << ", regenerating!" << std::dec << endl;
       regenerate = true;
    }
    l.addr = offset;
@@ -342,15 +342,15 @@ Address CodeBuffer::predictedAddr(unsigned id) {
    switch(label.type) {
       case Label::Absolute:
          //relocation_cerr << "\t\t Requested predicted addr for " << id
-//                         << ", label is absolute, ret " << hex << label.addr << dec << endl;
+//                         << ", label is absolute, ret " << std::hex << label.addr << std::dec << endl;
          return label.addr;
       case Label::Relative:
          assert(gen_.startAddr());
          assert(gen_.startAddr() != (Address) -1);
          //relocation_cerr << "\t\t Requested predicted addr for " << id
-//                         << ", label is relative, ret " << hex << label.addr + gen_.startAddr()
+//                         << ", label is relative, ret " << std::hex << label.addr + gen_.startAddr()
 //                         << " = " << label.addr << " + " << gen_.startAddr()
-            //             << dec << endl;
+            //             << std::dec << endl;
          return label.addr + gen_.startAddr();
       case Label::Estimate: {
          // In this case we want to adjust the address by 
@@ -363,11 +363,11 @@ Address CodeBuffer::predictedAddr(unsigned id) {
          if (label.iteration < curIteration_)
             ret += shift_;
          //relocation_cerr << "\t\t Requested predicted addr for " << id
-//                         << ", label is relative, ret " << hex << ret
+//                         << ", label is relative, ret " << std::hex << ret
     //                     << " = " << label.addr << " + " << gen_.startAddr()
    //                      << " + (" << label.iteration << " < " 
    //                      << curIteration_ << ") ? " << shift_ 
-   //                      << " : 0" << dec << endl;
+   //                      << " : 0" << std::dec << endl;
          return ret;
       }
       default:
diff --git a/dyninstAPI/src/Relocation/CodeMover.C b/dyninstAPI/src/Relocation/CodeMover.C
index aa9b02f..2d09932 100644
--- a/dyninstAPI/src/Relocation/CodeMover.C
+++ b/dyninstAPI/src/Relocation/CodeMover.C
@@ -86,7 +86,7 @@ bool CodeMover::addFunctions(FuncSet::const_iterator begin,
       // Add the function entry as Required in the priority map
       block_instance *entry = func->entryBlock();
       priorityMap_[std::make_pair(entry, func)] = Required;
-      relocation_cerr << "\t Added required entry for " << func->symTabName() << " / " << hex << entry->start() << dec << endl;
+      relocation_cerr << "\t Added required entry for " << func->symTabName() << " / " << std::hex << entry->start() << std::dec << endl;
    }
 
    return true;
@@ -107,7 +107,7 @@ bool CodeMover::addRelocBlock(block_instance *bbl, func_instance *f) {
    cfg_->addRelocBlock(block);
    
    if (!bbl->wasUserAdded()) {
-     relocation_cerr << "\t Added suggested entry for " << f->symTabName() << " / " << hex << bbl->start() << dec << endl;
+     relocation_cerr << "\t Added suggested entry for " << f->symTabName() << " / " << std::hex << bbl->start() << std::dec << endl;
      priorityMap_[std::make_pair(bbl, f)] = Suggested;
    }
 
@@ -225,8 +225,8 @@ SpringboardMap &CodeMover::sBoardMap(AddressSpace *) {
          func_instance *func = iter->first.second;
 
 	 relocation_cerr << "Func " << func->symTabName() << " / block " 
-			 << hex << bbl->start() << " /w/ priority " << p 
-			 << dec << endl;
+			 << std::hex << bbl->start() << " /w/ priority " << p 
+			 << std::dec << endl;
 
          if (bbl->wasUserAdded()) continue;
 
@@ -247,8 +247,8 @@ SpringboardMap &CodeMover::sBoardMap(AddressSpace *) {
    return sboardMap_;
 }
 
-string CodeMover::format() const {
-   stringstream ret;
+std::string CodeMover::format() const {
+   std::stringstream ret;
   
    ret << "CodeMover() {" << endl;
 
diff --git a/dyninstAPI/src/Relocation/CodeTracker.C b/dyninstAPI/src/Relocation/CodeTracker.C
index fe40c2d..6de40d1 100644
--- a/dyninstAPI/src/Relocation/CodeTracker.C
+++ b/dyninstAPI/src/Relocation/CodeTracker.C
@@ -203,12 +203,12 @@ void CodeTracker::debug() {
           iter2 != iter->second.end(); ++iter2) {
         for (FwdMapInner::const_iterator iter3 = iter2->second.begin();
              iter3 != iter2->second.end(); ++iter3) {
-           cerr << "\t\t" << hex \
+           cerr << "\t\t" << std::hex \
                 << iter3->first << " "
                 << iter3->second.instruction << "(insn)"
                 << iter3->second.instrumentation.size() << " (bts)"
                 << ", block @" << iter->first
-                << ", func @" << iter2->first << dec << endl;
+                << ", func @" << iter2->first << std::dec << endl;
         }
      }
   }
@@ -219,18 +219,18 @@ void CodeTracker::debug() {
   relocToOrig_.elements(reverseEntries);
   
   for (unsigned i = 0; i < reverseEntries.size(); ++i) {
-     cerr << "\t" << hex << reverseEntries[i].first.first << "-" 
+     cerr << "\t" << std::hex << reverseEntries[i].first.first << "-" 
           << reverseEntries[i].first.second << ": " 
-          << *(reverseEntries[i].second) << dec << endl;
+          << *(reverseEntries[i].second) << std::dec << endl;
   }
 
   cerr << endl;
 }
 
 std::ostream &operator<<(std::ostream &os, const Dyninst::Relocation::TrackerElement &e) {
-  os << "Tracker(" << hex
+  os << "Tracker(" << std::hex
      << e.orig() << "," << e.reloc() 
-     << "," << dec << e.size();
+     << "," << std::dec << e.size();
   switch(e.type()) {
   case TrackerElement::original:
     os << ",o";
@@ -249,6 +249,6 @@ std::ostream &operator<<(std::ostream &os, const Dyninst::Relocation::TrackerEle
     break;
   }
   os << "," << e.block()->start() << "," << (e.func() ? e.func()->name() : "<NOFUNC>");
-  os << ")" << dec;
+  os << ")" << std::dec;
   return os;
 }
diff --git a/dyninstAPI/src/Relocation/Springboard.C b/dyninstAPI/src/Relocation/Springboard.C
index 4d8ca65..1c60511 100644
--- a/dyninstAPI/src/Relocation/Springboard.C
+++ b/dyninstAPI/src/Relocation/Springboard.C
@@ -132,7 +132,7 @@ bool InstalledSpringboards::addFunc(func_instance* func)
 bool isNoneContained(std::set<ParseAPI::Block*> &blocks) {
     bool noneContained = true;
     for (auto block = blocks.begin(); block != blocks.end(); block++) {
-        springboard_cerr << hex << " Checking block " << (*block)->start() << "-" << (*block)->end() << dec << ": ";
+        springboard_cerr << std::hex << " Checking block " << (*block)->start() << "-" << (*block)->end() << std::dec << ": ";
         if ((*block)->containingFuncs() > 0) {
             std::vector<ParseAPI::Function *> funcs;
             springboard_cerr << "failure - contained by " << (*block)->containingFuncs() << " function(s): ";
@@ -287,7 +287,7 @@ SpringboardBuilder::generateSpringboard(std::list<codeGen> &springboards,
 bool SpringboardBuilder::generateMultiSpringboard(std::list<codeGen> &,
 						  const SpringboardReq &) {
    //debugRanges();
-   //if (false) cerr << "Request to generate multi-branch springboard skipped @ " << hex << r.from << dec << endl;
+   //if (false) cerr << "Request to generate multi-branch springboard skipped @ " << std::hex << r.from << std::dec << endl;
    // For now we give up and hope it all works out for the best. 
    return true;
 }
@@ -330,18 +330,18 @@ bool InstalledSpringboards::conflict(Address start, Address end, bool inRelocate
    Address UB = 0;
    SpringboardInfo *state = NULL;
    SpringboardInfo *lastState = state;
-   springboard_cerr << "Conflict called for " << hex << start << "->" << end << dec << endl;
+   springboard_cerr << "Conflict called for " << std::hex << start << "->" << end << std::dec << endl;
    
    while (end > working) {
-        springboard_cerr << "\t looking for " << hex << working << dec << endl;
+        springboard_cerr << "\t looking for " << std::hex << working << std::dec << endl;
        if (!validRanges_.find(working, LB, UB, state)) {
-         springboard_cerr << "\t Conflict: unable to find entry for " << hex << working << dec << endl;
+         springboard_cerr << "\t Conflict: unable to find entry for " << std::hex << working << std::dec << endl;
          return true;
        }
-       springboard_cerr << "\t\t Found " << hex << LB << " -> " << UB << " /w/ state " 
+       springboard_cerr << "\t\t Found " << std::hex << LB << " -> " << UB << " /w/ state " 
            << state->val << ", "
            << state->func->name() << ", priority " 
-           << state->priority << dec << endl;
+           << state->priority << std::dec << endl;
       if (state->val == Allocated) {
 	if(LB == start && UB >= end) 
 	{
@@ -402,14 +402,14 @@ bool InstalledSpringboards::conflictInRelocated(Address start, Address end) {
    }
    if ( (end-start) > 1 && relocTraps_.end() != relocTraps_.find(start) ) {
 #if 0
-       malware_cerr << "Springboard conflict for " << hex << start  
+       malware_cerr << "Springboard conflict for " << std::hex << start  
            << " our previous springboard here needed a trap, "
            << "but due to overwrites we may (erroneously) think "
-           << "a branch can fit" << dec << endl;
-       springboard_cerr << "Springboard conflict for " << hex << start  
+           << "a branch can fit" << std::dec << endl;
+       springboard_cerr << "Springboard conflict for " << std::hex << start  
            << " our previous springboard here needed a trap, "
            << "but due to overwrites we may (erroneously) think "
-           << "a branch can fit" << dec << endl;
+           << "a branch can fit" << std::dec << endl;
 #endif
        return true;
    }
@@ -456,7 +456,7 @@ void InstalledSpringboards::registerBranch
    Address working = start;
    Address LB = 0, UB = 0;
    Address lb = 0, ub = 0;
-   springboard_cerr << "Adding branch: " << hex << start << " -> " << end << dec << endl;
+   springboard_cerr << "Adding branch: " << std::hex << start << " -> " << end << std::dec << endl;
    int idToUse = -1;
    while (end > working) {
       SpringboardInfo* state = NULL;
@@ -481,13 +481,13 @@ void InstalledSpringboards::registerBranch
    // [end..ub] as true
    SpringboardInfo* info = new SpringboardInfo(idToUse, func);
    if (LB < start) {
-        springboard_cerr << "\tInserting prior space " << hex << LB << " -> " << start << " /w/ range " << idToUse << dec << endl;
+        springboard_cerr << "\tInserting prior space " << std::hex << LB << " -> " << start << " /w/ range " << idToUse << std::dec << endl;
        validRanges_.insert(LB, start, info);
    }
-    springboard_cerr << "\t Inserting taken space " << hex << start << " -> " << end << " /w/ range " << Allocated << dec << endl;
+    springboard_cerr << "\t Inserting taken space " << std::hex << start << " -> " << end << " /w/ range " << Allocated << std::dec << endl;
    validRanges_.insert(start, end, new SpringboardInfo(Allocated, func, p));
    if (UB > end) {
-        springboard_cerr << "\tInserting post space " << hex << end << " -> " << UB << " /w/ range " << idToUse << dec << endl;
+        springboard_cerr << "\tInserting post space " << std::hex << end << " -> " << UB << " /w/ range " << idToUse << std::dec << endl;
       validRanges_.insert(end, UB, info);
    }
 }
@@ -502,8 +502,8 @@ void InstalledSpringboards::debugRanges() {
   validRanges_.elements(elements);
   if (false) cerr << "Range debug: " << endl;
   for (unsigned i = 0; i < elements.size(); ++i) {
-     if (false) cerr << "\t" << hex << elements[i].first.first
-	 << ".." << elements[i].first.second << dec
+     if (false) cerr << "\t" << std::hex << elements[i].first.first
+	 << ".." << elements[i].first.second << std::dec
 	 << " -> " << elements[i].second->val << endl;
   }
   if (false) cerr << "-------------" << endl;
@@ -518,7 +518,7 @@ void SpringboardBuilder::generateBranch(Address from, Address to, codeGen &gen)
 
   insnCodeGen::generateBranch(gen, from, to);
 
-  springboard_cerr << "Generated springboard branch " << hex << from << "->" << to << dec << endl;
+  springboard_cerr << "Generated springboard branch " << std::hex << from << "->" << to << std::dec << endl;
 }
 
 void SpringboardBuilder::generateTrap(Address from, Address to, codeGen &gen) {
@@ -532,20 +532,20 @@ bool SpringboardBuilder::createRelocSpringboards(const SpringboardReq &req,
    assert(!req.fromRelocatedCode);
 
    // Just the requests for now.
-   springboard_cerr << "createRelocSpringboards for " << hex << req.from << dec << endl;
+   springboard_cerr << "createRelocSpringboards for " << std::hex << req.from << std::dec << endl;
    std::list<Address> relocAddrs;
    block_instance *bbl = req.block;
    for (SpringboardReq::Destinations::const_iterator b_iter = req.destinations.begin(); 
        b_iter != req.destinations.end(); ++b_iter) {
       func_instance *func = b_iter->first;
       Address addr = b_iter->second;
-      springboard_cerr << "Looking for addr " << hex << addr << " in function " << func->name() << dec << endl;
+      springboard_cerr << "Looking for addr " << std::hex << addr << " in function " << func->name() << std::dec << endl;
 
       addrSpace_->getRelocAddrs(req.from, bbl, func, relocAddrs, true);
       addrSpace_->getRelocAddrs(req.from, bbl, func, relocAddrs, false);
       for (std::list<Address>::const_reverse_iterator a_iter = relocAddrs.rbegin(); 
            a_iter != relocAddrs.rend(); ++a_iter) { 
-         //springboard_cerr << "\t Mapped address " << hex << *a_iter << dec << endl;
+         //springboard_cerr << "\t Mapped address " << std::hex << *a_iter << std::dec << endl;
          if (*a_iter == addr) continue;
          Priority newPriority;
          switch(req.priority) {
@@ -561,14 +561,14 @@ bool SpringboardBuilder::createRelocSpringboards(const SpringboardReq &req,
          }
          bool curUseTrap = useTrap;
          if ( !useTrap && installed_springboards_->forceTrap(*a_iter)) {
-            springboard_cerr << "Springboard conflict for " << hex 
+            springboard_cerr << "Springboard conflict for " << std::hex 
                              << req.from << "[" << (*a_iter) 
                              << "] our previous springboard here needed a trap, "
                              << "but due to overwrites we may (erroneously) think "
-                             << "a branch can fit" << dec << endl;
+                             << "a branch can fit" << std::dec << endl;
             curUseTrap = true;
          }
-         springboard_cerr << "Adding springboard from " << hex << *a_iter << " to " << addr << dec << endl;
+         springboard_cerr << "Adding springboard from " << std::hex << *a_iter << " to " << addr << std::dec << endl;
          input.addRaw(*a_iter, addr, 
                       newPriority, func, bbl,
                       req.checkConflicts, 
diff --git a/dyninstAPI/src/Relocation/Transformers/Defensive.C b/dyninstAPI/src/Relocation/Transformers/Defensive.C
index 46f2669..ccb24e6 100644
--- a/dyninstAPI/src/Relocation/Transformers/Defensive.C
+++ b/dyninstAPI/src/Relocation/Transformers/Defensive.C
@@ -139,7 +139,7 @@ bool DefensiveTransformer::requiresDefensivePad(const int_block *block) {
 
    if (callEdge && !ftEdge) {
        malware_cerr << "Found call edge w/o fallthrough, block @ " 
-           << hex << block->start() << " gets defensive pad " << dec << endl;
+           << std::hex << block->start() << " gets defensive pad " << std::dec << endl;
        return true;
    }
    else if (callEdge && ftEdge) {
@@ -160,7 +160,7 @@ bool DefensiveTransformer::requiresDefensivePad(const int_block *block) {
    if ((insns.back().first->getCategory() == c_CallInsn) &&
        (targets.empty())) 
    {
-       cerr << "Hacky defensive pad for block @ " << hex << block->start() << dec << endl;
+       cerr << "Hacky defensive pad for block @ " << std::hex << block->start() << std::dec << endl;
        return true;
    }
    return false;
diff --git a/dyninstAPI/src/Relocation/Transformers/Instrumenter.C b/dyninstAPI/src/Relocation/Transformers/Instrumenter.C
index 89491c5..ad2ccbf 100644
--- a/dyninstAPI/src/Relocation/Transformers/Instrumenter.C
+++ b/dyninstAPI/src/Relocation/Transformers/Instrumenter.C
@@ -58,7 +58,7 @@ bool Instrumenter::process(RelocBlock *trace,
       return true;
    }
 
-   relocation_cerr << "Processing trace " << trace->id() << " @ " << hex << trace->origAddr() << dec << endl;
+   relocation_cerr << "Processing trace " << trace->id() << " @ " << std::hex << trace->origAddr() << std::dec << endl;
 
    // Hoo boy. Fun for the whole family...
    //
@@ -155,7 +155,7 @@ bool Instrumenter::insnInstrumentation(RelocBlock *trace) {
          if (!pre->second->empty()) {
             Widget::Ptr inst = makeInstrumentation(pre->second);
             if (!inst) {
-	      relocation_cerr << "Failed to make pre-instrumentation at " << hex << preAddr << ", ret failed" << dec << endl;
+	      relocation_cerr << "Failed to make pre-instrumentation at " << std::hex << preAddr << ", ret failed" << std::dec << endl;
 	      return false;
 	    }
             trace->elements().insert(elem, inst);
@@ -171,7 +171,7 @@ bool Instrumenter::insnInstrumentation(RelocBlock *trace) {
                    ((*tmp)->insn())) ++tmp;
             Widget::Ptr inst = makeInstrumentation(post->second);
             if (!inst) {
-	      relocation_cerr << "Failed to make post-instrumentation at " << hex << postAddr << ", ret failed" << dec << endl;
+	      relocation_cerr << "Failed to make post-instrumentation at " << std::hex << postAddr << ", ret failed" << std::dec << endl;
 	      return false;
 	    }
             trace->elements().insert(tmp, inst);
diff --git a/dyninstAPI/src/Relocation/Transformers/Modification.C b/dyninstAPI/src/Relocation/Transformers/Modification.C
index 91a0249..673140d 100644
--- a/dyninstAPI/src/Relocation/Transformers/Modification.C
+++ b/dyninstAPI/src/Relocation/Transformers/Modification.C
@@ -81,9 +81,9 @@ bool Modification::replaceCall(RelocBlock *trace, RelocGraph *cfg) {
    relocation_cerr << "Replacing call in trace "
                    << trace->id() << " with call to "
                    << (repl ? repl->name() : "<NULL>")
-                   << ", " << hex
+                   << ", " << std::hex
                    << (repl ? repl->addr() : 0)
-                   << dec << endl;
+                   << std::dec << endl;
 
 
    // Replace the call at the end of this trace /w/ repl (if non-NULL),
@@ -192,7 +192,7 @@ bool Modification::wrapFunction(RelocBlock *trace, RelocGraph *cfg) {
    }
    else {
       relocation_cerr << "\t New function " << newfun->name() << " not relocated targeting entry block " 
-                      << hex << newfun->entryBlock()->start() << dec << " directly" << endl;
+                      << std::hex << newfun->entryBlock()->start() << std::dec << " directly" << endl;
       cfg->makeEdge(new Target<RelocBlock *>(stub),
                     new Target<block_instance *>(newfun->entryBlock()),
                     NULL,
diff --git a/dyninstAPI/src/Relocation/Transformers/Movement-adhoc.C b/dyninstAPI/src/Relocation/Transformers/Movement-adhoc.C
index ac0fef4..1b32d82 100644
--- a/dyninstAPI/src/Relocation/Transformers/Movement-adhoc.C
+++ b/dyninstAPI/src/Relocation/Transformers/Movement-adhoc.C
@@ -403,7 +403,7 @@ bool adhocMovementTransformer::isGetPC(Widget::Ptr ptr,
     const unsigned char* buf = reinterpret_cast<const unsigned char*>(addrSpace->getPtrToInstruction(target));
     if (!buf) {
        cerr << "Error: illegal pointer to buffer!" << endl;
-       cerr << "Target of " << hex << target << " from addr " << ptr->addr() << " in insn " << insn->format() << dec << endl;
+       cerr << "Target of " << std::hex << target << " from addr " << ptr->addr() << " in insn " << insn->format() << std::dec << endl;
        assert(0);
     }
 
@@ -452,7 +452,7 @@ bool adhocMovementTransformer::isGetPC(Widget::Ptr ptr,
     }
   }
   else {     
-     relocation_cerr << "\t Call to " << hex << target << " is not valid address, concluding not thunk" << dec << endl;
+     relocation_cerr << "\t Call to " << std::hex << target << " is not valid address, concluding not thunk" << std::dec << endl;
   }
   return false;
 }
diff --git a/dyninstAPI/src/Relocation/Transformers/Movement-analysis.C b/dyninstAPI/src/Relocation/Transformers/Movement-analysis.C
index fcca7dc..3f121d1 100644
--- a/dyninstAPI/src/Relocation/Transformers/Movement-analysis.C
+++ b/dyninstAPI/src/Relocation/Transformers/Movement-analysis.C
@@ -125,7 +125,7 @@ bool PCSensitiveTransformer::process(RelocBlock *reloc, RelocGraph *g) {
 
     Sens_++;
 
-    sensitivity_cerr << "Instruction is sensitive @ " << hex << addr << dec << endl;
+    sensitivity_cerr << "Instruction is sensitive @ " << std::hex << addr << std::dec << endl;
 
     // Optimization: before we do some heavyweight analysis, see if we can shortcut
     bool intSens = false;
@@ -134,7 +134,7 @@ bool PCSensitiveTransformer::process(RelocBlock *reloc, RelocGraph *g) {
     Absloc dest;
 
     if (insnIsThunkCall(insn, addr, dest)) {
-      //relocation_cerr << "Thunk @ " << hex << addr << dec << endl;
+      //relocation_cerr << "Thunk @ " << std::hex << addr << std::dec << endl;
        handleThunkCall(reloc, g, iter, dest);
        intSens_++;
        extSens_++;
@@ -144,14 +144,14 @@ bool PCSensitiveTransformer::process(RelocBlock *reloc, RelocGraph *g) {
 
     if (exceptionSensitive(addr+insn->size(), block)) {
       extSens = true;
-      sensitivity_cerr << "Sensitive by exception @ " << hex << addr << dec << endl;
+      sensitivity_cerr << "Sensitive by exception @ " << std::hex << addr << std::dec << endl;
     }
 
     if (!queryCache(block, addr, intSens, extSens)) {
        for (AssignList::iterator a_iter = sensitiveAssignments.begin();
             a_iter != sensitiveAssignments.end(); ++a_iter) {
           
-		//cerr << "Forward slice from " << (*a_iter)->format() << hex << " @ " << addr << " (parse of " << (*a_iter)->addr() << dec << ") in func " << block->func()->prettyName() << endl;
+		//cerr << "Forward slice from " << (*a_iter)->format() << std::hex << " @ " << addr << " (parse of " << (*a_iter)->addr() << std::dec << ") in func " << block->func()->prettyName() << endl;
           
           Graph::Ptr slice = forwardSlice(*a_iter,
                                           block->llb(),
@@ -267,7 +267,7 @@ bool PCSensitiveTransformer::isPCSensitive(Instruction::Ptr insn,
     for (std::vector<AbsRegion>::const_iterator i = ins.begin();
 	 i != ins.end(); ++i) {
       if (i->contains(pc)) {
-	//relocation_cerr << insn->format() << " @" << hex << addr << dec << " is PCsens" << endl;
+	//relocation_cerr << insn->format() << " @" << std::hex << addr << std::dec << " is PCsens" << endl;
 	sensitiveAssignments.push_back(*a_iter);
       }
     }
@@ -389,7 +389,7 @@ bool PCSensitiveTransformer::determineSensitivity(Graph::Ptr slice,
 
     if (v.isExtSens(ast)) {
       //cerr << "\t\t is externally sensitive" << endl;
-      //cerr << "\t\t\t @ " << hex << aNode->addr() << dec << endl;
+      //cerr << "\t\t\t @ " << std::hex << aNode->addr() << std::dec << endl;
       external = true;
     }
     else {
@@ -816,7 +816,7 @@ bool PCSensitiveTransformer::isSyscall(InstructionAPI::Instruction::Ptr insn, Ad
   static Expression::Ptr x86_gs(new RegisterAST(x86::gs));
 
   if (insn->isRead(x86_gs)) {
-    //relocation_cerr << "Skipping syscall " << insn->format() << hex << "@ " << addr << dec << endl;
+    //relocation_cerr << "Skipping syscall " << insn->format() << std::hex << "@ " << addr << std::dec << endl;
     return true;
   }
   return false;
diff --git a/dyninstAPI/src/Relocation/Widgets/CFPatch.C b/dyninstAPI/src/Relocation/Widgets/CFPatch.C
index 5279f17..3e8ac44 100644
--- a/dyninstAPI/src/Relocation/Widgets/CFPatch.C
+++ b/dyninstAPI/src/Relocation/Widgets/CFPatch.C
@@ -75,14 +75,14 @@ bool CFPatch::apply(codeGen &gen, CodeBuffer *buf) {
    int targetLabel = target->label(buf);
 
    relocation_cerr << "\t\t CFPatch::apply(" 
-		   << hex << this << dec << "), type " << type << ", origAddr " << hex << origAddr_ 
-                   << ", and label " << dec << targetLabel << endl;
+		   << std::hex << this << std::dec << "), type " << type << ", origAddr " << std::hex << origAddr_ 
+                   << ", and label " << std::dec << targetLabel << endl;
    if (orig_insn) {
-      relocation_cerr << "\t\t\t Currently at " << hex << gen.currAddr() << " and targeting predicted " << buf->predictedAddr(targetLabel) << dec << endl;
+      relocation_cerr << "\t\t\t Currently at " << std::hex << gen.currAddr() << " and targeting predicted " << buf->predictedAddr(targetLabel) << std::dec << endl;
       switch(type) {
          case CFPatch::Jump: {
             relocation_cerr << "\t\t\t Generating CFPatch::Jump from " 
-                            << hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << dec << endl;
+                            << std::hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << std::dec << endl;
             if (!insnCodeGen::modifyJump(buf->predictedAddr(targetLabel), *ugly_insn, gen)) {
                cerr << "Failed to modify jump" << endl;
                return false;
@@ -91,7 +91,7 @@ bool CFPatch::apply(codeGen &gen, CodeBuffer *buf) {
          }
          case CFPatch::JCC: {
             relocation_cerr << "\t\t\t Generating CFPatch::JCC from " 
-                            << hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << dec << endl;            
+                            << std::hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << std::dec << endl;            
             if (!insnCodeGen::modifyJcc(buf->predictedAddr(targetLabel), *ugly_insn, gen)) {
                cerr << "Failed to modify conditional jump" << endl;
                return false;
diff --git a/dyninstAPI/src/Relocation/Widgets/CFWidget-ppc.C b/dyninstAPI/src/Relocation/Widgets/CFWidget-ppc.C
index 3d4a394..7c72677 100644
--- a/dyninstAPI/src/Relocation/Widgets/CFWidget-ppc.C
+++ b/dyninstAPI/src/Relocation/Widgets/CFWidget-ppc.C
@@ -113,15 +113,15 @@ bool CFPatch::apply(codeGen &gen, CodeBuffer *buf) {
    // Otherwise this is a classic, and therefore easy.
    int targetLabel = target->label(buf);
 
-   relocation_cerr << "\t\t CFPatch::apply, type " << type << ", origAddr " << hex << origAddr_ 
-                   << ", and label " << dec << targetLabel << endl;
+   relocation_cerr << "\t\t CFPatch::apply, type " << type << ", origAddr " << std::hex << origAddr_ 
+                   << ", and label " << std::dec << targetLabel << endl;
 
    if (orig_insn) {
-      relocation_cerr << "\t\t\t Currently at " << hex << gen.currAddr() << " and targeting predicted " << buf->predictedAddr(targetLabel) << dec << endl;
+      relocation_cerr << "\t\t\t Currently at " << std::hex << gen.currAddr() << " and targeting predicted " << buf->predictedAddr(targetLabel) << std::dec << endl;
       switch(type) {
          case CFPatch::Jump: {
             relocation_cerr << "\t\t\t Generating CFPatch::Jump from " 
-                            << hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << dec << endl;
+                            << std::hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << std::dec << endl;
             if (!insnCodeGen::modifyJump(buf->predictedAddr(targetLabel), *ugly_insn, gen)) {
 	      relocation_cerr << "modifyJump failed, ret false" << endl;
                return false;
@@ -130,7 +130,7 @@ bool CFPatch::apply(codeGen &gen, CodeBuffer *buf) {
          }
          case CFPatch::JCC: {
             relocation_cerr << "\t\t\t Generating CFPatch::JCC from " 
-                            << hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << dec << endl;            
+                            << std::hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << std::dec << endl;            
             if (!insnCodeGen::modifyJcc(buf->predictedAddr(targetLabel), *ugly_insn, gen)) {
 	      relocation_cerr << "modifyJcc failed, ret false" << endl;
                return false;
diff --git a/dyninstAPI/src/Relocation/Widgets/CFWidget-x86.C b/dyninstAPI/src/Relocation/Widgets/CFWidget-x86.C
index c3d544f..6df0a44 100644
--- a/dyninstAPI/src/Relocation/Widgets/CFWidget-x86.C
+++ b/dyninstAPI/src/Relocation/Widgets/CFWidget-x86.C
@@ -172,14 +172,14 @@ bool CFPatch::apply(codeGen &gen, CodeBuffer *buf) {
    // Otherwise this is a classic, and therefore easy.
    int targetLabel = target->label(buf);
 
-   relocation_cerr << "\t\t CFPatch::apply, type " << type << ", origAddr " << hex << origAddr_ 
-                   << ", and label " << dec << targetLabel << endl;
+   relocation_cerr << "\t\t CFPatch::apply, type " << type << ", origAddr " << std::hex << origAddr_ 
+                   << ", and label " << std::dec << targetLabel << endl;
    if (orig_insn) {
-      relocation_cerr << "\t\t\t Currently at " << hex << gen.currAddr() << " and targeting predicted " << buf->predictedAddr(targetLabel) << dec << endl;
+      relocation_cerr << "\t\t\t Currently at " << std::hex << gen.currAddr() << " and targeting predicted " << buf->predictedAddr(targetLabel) << std::dec << endl;
       switch(type) {
          case CFPatch::Jump: {
             relocation_cerr << "\t\t\t Generating CFPatch::Jump from " 
-                            << hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << dec << endl;
+                            << std::hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << std::dec << endl;
             if (!insnCodeGen::modifyJump(buf->predictedAddr(targetLabel), *ugly_insn, gen)) {
                cerr << "Failed to modify jump" << endl;
                return false;
@@ -188,7 +188,7 @@ bool CFPatch::apply(codeGen &gen, CodeBuffer *buf) {
          }
          case CFPatch::JCC: {
             relocation_cerr << "\t\t\t Generating CFPatch::JCC from " 
-                            << hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << dec << endl;            
+                            << std::hex << gen.currAddr() << " to " << buf->predictedAddr(targetLabel) << std::dec << endl;            
             if (!insnCodeGen::modifyJcc(buf->predictedAddr(targetLabel), *ugly_insn, gen)) {
                cerr << "Failed to modify conditional jump" << endl;
                return false;
diff --git a/dyninstAPI/src/Relocation/Widgets/CFWidget.C b/dyninstAPI/src/Relocation/Widgets/CFWidget.C
index c432ccf..6f9a6df 100644
--- a/dyninstAPI/src/Relocation/Widgets/CFWidget.C
+++ b/dyninstAPI/src/Relocation/Widgets/CFWidget.C
@@ -435,7 +435,7 @@ bool CFWidget::generateConditionalBranch(CodeBuffer &buffer,
 
 
 std::string CFWidget::format() const {
-   stringstream ret;
+   std::stringstream ret;
    ret << "CFWidget(" << std::hex;
    ret << addr_ << ",";
    if (isIndirect_) ret << "<ind>";
@@ -501,7 +501,7 @@ unsigned CFPatch::estimate(codeGen &) {
 PaddingPatch::PaddingPatch(unsigned size, bool registerDefensive, bool noop, block_instance *b)
   : size_(size), registerDefensive_(registerDefensive), noop_(noop), block_(b) 
 {
-   //malware_cerr << hex << "PaddingPatch(" << size << "," << registerDefensive << "," << noop << ", [" << b->start() << " " << b->end() << ") )" << dec <<  endl;
+   //malware_cerr << std::hex << "PaddingPatch(" << size << "," << registerDefensive << "," << noop << ", [" << b->start() << " " << b->end() << ") )" << std::dec <<  endl;
 }
 
 
@@ -512,7 +512,7 @@ bool PaddingPatch::apply(codeGen &gen, CodeBuffer *) {
       bpwarn("WARNING: Disabling post-call block padding %s[%d]\n",FILE__,__LINE__);
       return true;
    }
-   //malware_cerr << "PaddingPatch::apply, addr [" << hex << block_->end() << "]["<< gen.currAddr() << "], size " << size_ << ", registerDefensive " << (registerDefensive_ ? "<true>" : "<false>") << dec << endl;
+   //malware_cerr << "PaddingPatch::apply, addr [" << std::hex << block_->end() << "]["<< gen.currAddr() << "], size " << size_ << ", registerDefensive " << (registerDefensive_ ? "<true>" : "<false>") << std::dec << endl;
    if (noop_) {
       gen.fill(size_, codeGen::cgNOP);
    }
@@ -521,7 +521,7 @@ bool PaddingPatch::apply(codeGen &gen, CodeBuffer *) {
    } else {
       gen.fill(size_, codeGen::cgTrap);
    }
-   //cerr << "\t After filling, current addr " << hex << gen.currAddr() << dec << endl;
+   //cerr << "\t After filling, current addr " << std::hex << gen.currAddr() << std::dec << endl;
    //gen.fill(10, codeGen::cgNOP);
    return true;
 }
diff --git a/dyninstAPI/src/Relocation/Widgets/InsnWidget.C b/dyninstAPI/src/Relocation/Widgets/InsnWidget.C
index da53bc4..6c2426b 100644
--- a/dyninstAPI/src/Relocation/Widgets/InsnWidget.C
+++ b/dyninstAPI/src/Relocation/Widgets/InsnWidget.C
@@ -62,11 +62,11 @@ InsnWidget::Ptr InsnWidget::create(Instruction::Ptr insn,
 InsnWidget::InsnWidget(Instruction::Ptr insn, Address addr) :
    insn_(insn), addr_(addr) {}
 
-string InsnWidget::format() const {
-	stringstream ret;
+std::string InsnWidget::format() const {
+	std::stringstream ret;
  // ret << "Insn(" << insn_->format() << ")";
-	ret << "Insn(" << hex << addr_ 
-	    << ": " << insn_->format(addr_) << dec << ")";
+	ret << "Insn(" << std::hex << addr_ 
+	    << ": " << insn_->format(addr_) << std::dec << ")";
 	return ret.str();
 }
 
diff --git a/dyninstAPI/src/Relocation/Widgets/PCWidget.C b/dyninstAPI/src/Relocation/Widgets/PCWidget.C
index 4c99204..188456a 100644
--- a/dyninstAPI/src/Relocation/Widgets/PCWidget.C
+++ b/dyninstAPI/src/Relocation/Widgets/PCWidget.C
@@ -159,8 +159,8 @@ bool PCWidget::PCtoReg(const codeGen &templ, const RelocBlock *t, CodeBuffer &bu
   return true;
 }
 
-string PCWidget::format() const {
-  stringstream ret;
+std::string PCWidget::format() const {
+  std::stringstream ret;
   ret << "PCWidget(" 
       << std::hex << addr_ << std::dec;
   ret << "" << a_.format();
diff --git a/dyninstAPI/src/Relocation/Widgets/RelDataWidget.C b/dyninstAPI/src/Relocation/Widgets/RelDataWidget.C
index f0db10c..12b0ea0 100644
--- a/dyninstAPI/src/Relocation/Widgets/RelDataWidget.C
+++ b/dyninstAPI/src/Relocation/Widgets/RelDataWidget.C
@@ -74,8 +74,8 @@ bool RelDataWidget::generate(const codeGen &,
   return true;
 }
 
-string RelDataWidget::format() const {
-  stringstream ret;
+std::string RelDataWidget::format() const {
+  std::stringstream ret;
   ret << "PCRel(" << insn_->format() << ")";
   return ret.str();
 }
diff --git a/dyninstAPI/src/Relocation/Widgets/StackModWidget.C b/dyninstAPI/src/Relocation/Widgets/StackModWidget.C
index 9dc1507..75e408b 100644
--- a/dyninstAPI/src/Relocation/Widgets/StackModWidget.C
+++ b/dyninstAPI/src/Relocation/Widgets/StackModWidget.C
@@ -67,8 +67,8 @@ bool StackModWidget::generate(const codeGen &,
   return true;
 }
 
-string StackModWidget::format() const {
-  stringstream ret;
+std::string StackModWidget::format() const {
+  std::stringstream ret;
   ret << "MemRel(" << insn_->format() << ")";
   return ret.str();
 }
diff --git a/dyninstAPI/src/StackMod/StackModChecker.C b/dyninstAPI/src/StackMod/StackModChecker.C
index f923579..5ad1d71 100644
--- a/dyninstAPI/src/StackMod/StackModChecker.C
+++ b/dyninstAPI/src/StackMod/StackModChecker.C
@@ -646,7 +646,7 @@ bool StackModChecker::accumulateStackRanges(StackMod* m)
 
     bool found = false;
     int removeRangeAt = -1;
-    std::set<std::pair<int, pair<int, StackMod::MType> > > newRanges;
+    std::set<std::pair<int, std::pair<int, StackMod::MType> > > newRanges;
 
     rangeIterator begin, end;
     if (m->order() == StackMod::NEW) {
@@ -680,12 +680,12 @@ bool StackModChecker::accumulateStackRanges(StackMod* m)
             if ( (start <= low) && (low <= end) ) {
                 found = true;
                 removeRangeAt = start; // This is inefficient...
-                newRanges.insert(make_pair(start, make_pair(high, type)));
+                newRanges.insert(std::make_pair(start, std::make_pair(high, type)));
                 break;
             } else if ( (start <= high) && (high <= end) ) {
                 found = true;
                 removeRangeAt = start;
-                newRanges.insert(make_pair(low, make_pair(end, type)));
+                newRanges.insert(std::make_pair(low, std::make_pair(end, type)));
                 break;
             }
         } else {
@@ -697,14 +697,14 @@ bool StackModChecker::accumulateStackRanges(StackMod* m)
                 found = true;
                 removeRangeAt = start;
                 if (!(start == low)) {
-                    newRanges.insert(make_pair(start, make_pair(low, type)));
+                    newRanges.insert(std::make_pair(start, std::make_pair(low, type)));
                 } 
 
                 if (!(end == high)) {
-                    newRanges.insert(make_pair(high, make_pair(end, type)));
+                    newRanges.insert(std::make_pair(high, std::make_pair(end, type)));
                 }
 
-                newRanges.insert(make_pair(low, make_pair(high, curType)));
+                newRanges.insert(std::make_pair(low, std::make_pair(high, curType)));
             }
             // 2. m's range encloses an existing range
             //      remove existing ranges
@@ -712,21 +712,21 @@ bool StackModChecker::accumulateStackRanges(StackMod* m)
             if ( (low < start) && (high > end) ) {
                 found = true;
                 removeRangeAt = start;
-                newRanges.insert(make_pair(low, make_pair(high, curType)));
+                newRanges.insert(std::make_pair(low, std::make_pair(high, curType)));
             }
             // 3. m's range overlaps with start
             if ( (low < start) && (high > start) && (high < end) ) {
                 found = true;
                 removeRangeAt = start;
-                newRanges.insert(make_pair(low, make_pair(high, curType)));
-                newRanges.insert(make_pair(high, make_pair(end, type)));
+                newRanges.insert(std::make_pair(low, std::make_pair(high, curType)));
+                newRanges.insert(std::make_pair(high, std::make_pair(end, type)));
             }
             // 4. m's range overlaps with end
             if ( (low > start) && (low < end) && (high > end) ) {
                 found = true;
                 removeRangeAt = start;
-                newRanges.insert(make_pair(start, make_pair(low, type)));
-                newRanges.insert(make_pair(low, make_pair(high, curType)));
+                newRanges.insert(std::make_pair(start, std::make_pair(low, type)));
+                newRanges.insert(std::make_pair(low, std::make_pair(high, curType)));
             }
         }
     }
@@ -747,9 +747,9 @@ bool StackModChecker::accumulateStackRanges(StackMod* m)
         }
     } else {
         if (m->order() == StackMod::NEW) {
-            _stackRanges.insert(make_pair(low, make_pair(high, curType)));
+            _stackRanges.insert(std::make_pair(low, std::make_pair(high, curType)));
         } else if (m->order() == StackMod::CLEANUP) {
-            _stackRangesCleanup.insert(make_pair(low, make_pair(high, curType)));
+            _stackRangesCleanup.insert(std::make_pair(low, std::make_pair(high, curType)));
         }
     }
 
@@ -901,7 +901,7 @@ void StackModChecker::processBlock(StackAnalysis& sa, ParseAPI::Block* block)
         }
     }
 
-    blockHeights.insert(make_pair(block, heightVec));
+    blockHeights.insert(std::make_pair(block, heightVec));
 }
 
 /* Check the stack growth for all paths in the function */
diff --git a/dyninstAPI/src/StackMod/StackModChecker.h b/dyninstAPI/src/StackMod/StackModChecker.h
index 2c1ed2d..3e1f8b9 100644
--- a/dyninstAPI/src/StackMod/StackModChecker.h
+++ b/dyninstAPI/src/StackMod/StackModChecker.h
@@ -55,7 +55,7 @@ class StackModChecker
         func_instance* func;
 
     private:
-        typedef map<int, pair<int, StackMod::MType> > rangeMap;
+        typedef std::map<int, std::pair<int, StackMod::MType> > rangeMap;
         typedef rangeMap::iterator rangeIterator;
 
         std::string getName() const;
diff --git a/dyninstAPI/src/addressSpace.C b/dyninstAPI/src/addressSpace.C
index 878563b..f284ed6 100644
--- a/dyninstAPI/src/addressSpace.C
+++ b/dyninstAPI/src/addressSpace.C
@@ -315,9 +315,9 @@ void AddressSpace::inferiorFreeCompact() {
 
    /* sort buffers by address */
 #if defined (cap_use_pdvector)
-    std::sort(freeList.begin(), freeList.end(), ptr_fun(heapItemCmpByAddr));
+    std::sort(freeList.begin(), freeList.end(), std::ptr_fun(heapItemCmpByAddr));
 #else
-    std::sort(freeList.begin(), freeList.end(), ptr_fun(heapItemLessByAddr));
+    std::sort(freeList.begin(), freeList.end(), std::ptr_fun(heapItemLessByAddr));
 #endif
 
 
@@ -406,7 +406,7 @@ void AddressSpace::addHeap(heapItem *h) {
    heap_.heapFree.push_back(h2);
     
    /* When we add an item to heapFree, make sure it remains in sorted order */
-   std::sort(heap_.heapFree.begin(), heap_.heapFree.end(), ptr_fun(heapItemLessByAddr));
+   std::sort(heap_.heapFree.begin(), heap_.heapFree.end(), std::ptr_fun(heapItemLessByAddr));
 
    heap_.totalFreeMemAvailable += h2->length;
 
@@ -464,7 +464,7 @@ Address AddressSpace::inferiorMallocInternal(unsigned size,
    }
 
    /* When we update an item in heapFree, make sure it remains in sorted order */
-   std::sort(heap_.heapFree.begin(), heap_.heapFree.end(), ptr_fun(heapItemLessByAddr));
+   std::sort(heap_.heapFree.begin(), heap_.heapFree.end(), std::ptr_fun(heapItemLessByAddr));
 
    // add allocated block to active list
    h->length = size;
@@ -494,7 +494,7 @@ void AddressSpace::inferiorFreeInternal(Address block) {
    heap_.heapFree.push_back(h);
 
    /* When we add an item to heapFree, make sure it remains in sorted order */
-   std::sort(heap_.heapFree.begin(), heap_.heapFree.end(), ptr_fun(heapItemLessByAddr));
+   std::sort(heap_.heapFree.begin(), heap_.heapFree.end(), std::ptr_fun(heapItemLessByAddr));
 
    heap_.totalFreeMemAvailable += h->length;
    heap_.freed += h->length;
@@ -600,7 +600,7 @@ bool AddressSpace::inferiorShrinkBlock(heapItem *h,
       heap_.heapFree.push_back(freeEnd);
 
       /* When we add an item to heapFree, make sure it remains sorted */
-      std::sort(heap_.heapFree.begin(), heap_.heapFree.end(), ptr_fun(heapItemLessByAddr));
+      std::sort(heap_.heapFree.begin(), heap_.heapFree.end(), std::ptr_fun(heapItemLessByAddr));
    }
 
    heap_.totalFreeMemAvailable += shrink;
@@ -752,8 +752,8 @@ bool AddressSpace::findFuncsByMangled(const std::string &funcname,
    return res.size() != starting_entries;
 }
 
-func_instance *AddressSpace::findOnlyOneFunction(const string &name,
-                                                 const string &lib,
+func_instance *AddressSpace::findOnlyOneFunction(const std::string &name,
+                                                 const std::string &lib,
                                                  bool /*search_rt_lib*/) 
 {
    assert(mapped_objects.size());
@@ -1778,11 +1778,11 @@ bool AddressSpace::relocateInt(FuncSet::const_iterator begin, FuncSet::const_ite
         (cm->ptr(),cm->size(),getArch());
       Instruction::Ptr insn = deco.decode();
       while(insn) {
-         cerr << "\t" << hex << base << ": " << insn->format(base) << dec << endl;
+         cerr << "\t" << std::hex << base << ": " << insn->format(base) << std::dec << endl;
         base += insn->size();
         insn = deco.decode();
       }
-      cerr << dec;
+      cerr << std::dec;
       cerr << endl;
  //     cerr << cm->format() << endl;
 
@@ -2003,12 +2003,12 @@ bool AddressSpace::patchCode(CodeMover::Ptr cm,
   for (std::list<codeGen>::iterator iter = patches.begin();
        iter != patches.end(); ++iter) 
   {
-      springboard_cerr << "Writing springboard @ " << hex << iter->startAddr() << endl;
+      springboard_cerr << "Writing springboard @ " << std::hex << iter->startAddr() << endl;
       if (!writeTextSpace((void *)iter->startAddr(),
           iter->used(),
           iter->start_ptr())) 
       {
-	springboard_cerr << "\t FAILED to write springboard @ " << hex << iter->startAddr() << endl;
+	springboard_cerr << "\t FAILED to write springboard @ " << std::hex << iter->startAddr() << endl;
          // HACK: code modification will make this happen...
          return false;
       }
@@ -2036,11 +2036,11 @@ void AddressSpace::getRelocAddrs(Address orig,
                                  func_instance *func,
                                  std::list<Address> &relocs,
                                  bool getInstrumentationAddrs) const {
-  springboard_cerr << "getRelocAddrs for orig addr " << hex << orig << " /w/ block start " << block->start() << dec << endl;
+  springboard_cerr << "getRelocAddrs for orig addr " << std::hex << orig << " /w/ block start " << block->start() << std::dec << endl;
   for (CodeTrackers::const_iterator iter = relocatedCode_.begin();
        iter != relocatedCode_.end(); ++iter) {
     Relocation::CodeTracker::RelocatedElements reloc;
-    //springboard_cerr << "\t Checking CodeTracker " << hex << *iter << dec << endl;
+    //springboard_cerr << "\t Checking CodeTracker " << std::hex << *iter << std::dec << endl;
     if ((*iter)->origToReloc(orig, block, func, reloc)) {
       // Pick instrumentation if it's there, otherwise use the reloc instruction
        //springboard_cerr << "\t\t ... match" << endl;
diff --git a/dyninstAPI/src/ast.C b/dyninstAPI/src/ast.C
index c9c59ca..9e0c1fe 100644
--- a/dyninstAPI/src/ast.C
+++ b/dyninstAPI/src/ast.C
@@ -204,8 +204,8 @@ AstNodePtr AstNode::sequenceNode(pdvector<AstNodePtr > &sequence) {
     return AstNodePtr(new AstSequenceNode(sequence));
 }
 
-AstNodePtr AstNode::variableNode(vector<AstNodePtr> &ast_wrappers,
-                                 vector<pair<Offset, Offset> >*ranges) {
+AstNodePtr AstNode::variableNode(std::vector<AstNodePtr> &ast_wrappers,
+                                 std::vector<std::pair<Offset, Offset> >*ranges) {
     return AstNodePtr(new AstVariableNode(ast_wrappers, ranges));
 }
 
@@ -467,10 +467,10 @@ AstSequenceNode::AstSequenceNode(pdvector<AstNodePtr > &sequence) :
     }
 }
 
-AstVariableNode::AstVariableNode(vector<AstNodePtr>&ast_wrappers, vector<pair<Offset, Offset> > *ranges) :
+AstVariableNode::AstVariableNode(std::vector<AstNodePtr>&ast_wrappers, std::vector<std::pair<Offset, Offset> > *ranges) :
     ast_wrappers_(ast_wrappers), ranges_(ranges), index(0)
 {
-   vector<AstNodePtr>::iterator i;
+   std::vector<AstNodePtr>::iterator i;
    assert(!ast_wrappers_.empty());
 
    for (i = ast_wrappers.begin(); i != ast_wrappers.end(); i++) {
@@ -1608,7 +1608,7 @@ bool AstOperatorNode::generateCode_phase2(codeGen &gen, bool noCost,
                break;
             default:
                cerr << "Uh oh, unknown loperand type in getAddrOp: " << loperand->getoType() << endl;
-               cerr << "\t Generating ast " << hex << this << dec << endl;
+               cerr << "\t Generating ast " << std::hex << this << std::dec << endl;
                assert(0);
          }
          break;
@@ -3314,11 +3314,11 @@ void AstVariableNode::setVariableAST(codeGen &gen){
        }
     }
     if (!found) {
-       cerr << "Error: unable to find AST representing variable at " << hex << addr << dec << endl;
-       cerr << "Pointer " << hex << this << dec << endl;
+       cerr << "Error: unable to find AST representing variable at " << std::hex << addr << std::dec << endl;
+       cerr << "Pointer " << std::hex << this << std::dec << endl;
        cerr << "Options are: " << endl;
        for(unsigned i=0; i< ranges_->size();i++){
-          cerr << "\t" << hex << (*ranges_)[i].first << "-" << (*ranges_)[i].second << dec << endl;
+          cerr << "\t" << std::hex << (*ranges_)[i].first << "-" << (*ranges_)[i].second << std::dec << endl;
        }
     }
     assert(found);
@@ -3718,19 +3718,19 @@ bool AstSnippetNode::generateCode_phase2(codeGen &gen,
 
 std::string AstNode::format(std::string indent) {
    std::stringstream ret;
-   ret << indent << "Default/" << hex << this << dec << "()" << endl;
+   ret << indent << "Default/" << std::hex << this << std::dec << "()" << endl;
    return ret.str();
 }
 
 std::string AstNullNode::format(std::string indent) {
    std::stringstream ret;
-   ret << indent << "Null/" << hex << this << dec << "()" << endl;
+   ret << indent << "Null/" << std::hex << this << std::dec << "()" << endl;
    return ret.str();
 }
 
 std::string AstStackInsertNode::format(std::string indent) {
     std::stringstream ret;
-    ret << indent << "StackInsert/" << hex << this;
+    ret << indent << "StackInsert/" << std::hex << this;
     ret << "(size " << size << ")";
     if (type == CANARY_AST) ret << " (is canary)";
     ret << endl;
@@ -3739,7 +3739,7 @@ std::string AstStackInsertNode::format(std::string indent) {
 
 std::string AstStackRemoveNode::format(std::string indent) {
     std::stringstream ret;
-    ret << indent << "StackRemove/" << hex << this;
+    ret << indent << "StackRemove/" << std::hex << this;
     ret << "(size " << size << ")";
     if (type == CANARY_AST) ret << "(is canary)";
     ret << endl;
@@ -3748,14 +3748,14 @@ std::string AstStackRemoveNode::format(std::string indent) {
 
 std::string AstStackGenericNode::format(std::string indent) {
     std::stringstream ret;
-    ret << indent << "StackGeneric/" << hex << this;
+    ret << indent << "StackGeneric/" << std::hex << this;
     ret << endl;
     return ret.str();
 }
 
 std::string AstOperatorNode::format(std::string indent) {
    std::stringstream ret;
-   ret << indent << "Op/" << hex << this << dec << "(" << convert(op) << ")" << endl;
+   ret << indent << "Op/" << std::hex << this << std::dec << "(" << convert(op) << ")" << endl;
    if (loperand) ret << indent << loperand->format(indent + "  ");
    if (roperand) ret << indent << roperand->format(indent + "  ");
    if (eoperand) ret << indent << eoperand->format(indent + "  ");
@@ -3765,7 +3765,7 @@ std::string AstOperatorNode::format(std::string indent) {
 
 std::string AstOperandNode::format(std::string indent) {
    std::stringstream ret;
-   ret << indent << "Oper/" << hex << this << dec << "(" << convert(oType) << "/" << oValue << ")" << endl;
+   ret << indent << "Oper/" << std::hex << this << std::dec << "(" << convert(oType) << "/" << oValue << ")" << endl;
    if (operand_) ret << indent << operand_->format(indent + "  ");
 
    return ret.str();
@@ -3774,7 +3774,7 @@ std::string AstOperandNode::format(std::string indent) {
 
 std::string AstCallNode::format(std::string indent) {
    std::stringstream ret;
-   ret << indent << "Call/" << hex << this << dec;
+   ret << indent << "Call/" << std::hex << this << std::dec;
    if (func_) ret << "(" << func_->name() << ")";
    else ret << "(" << func_name_ << ")";
    ret << endl;
@@ -3788,7 +3788,7 @@ std::string AstCallNode::format(std::string indent) {
 
 std::string AstSequenceNode::format(std::string indent) {
    std::stringstream ret;
-   ret << indent << "Seq/" << hex << this << dec << "()" << endl;
+   ret << indent << "Seq/" << std::hex << this << std::dec << "()" << endl;
    for (unsigned i = 0; i < sequence_.size(); ++i) {
       ret << indent << sequence_[i]->format(indent + "  ");
    }
@@ -3798,7 +3798,7 @@ std::string AstSequenceNode::format(std::string indent) {
 
 std::string AstVariableNode::format(std::string indent) {
    std::stringstream ret;
-   ret << indent << "Var/" << hex << this << dec << "(" << ast_wrappers_.size() << ")" << endl;
+   ret << indent << "Var/" << std::hex << this << std::dec << "(" << ast_wrappers_.size() << ")" << endl;
    for (unsigned i = 0; i < ast_wrappers_.size(); ++i) {
       ret << indent << ast_wrappers_[i]->format(indent + "  ");
    }
@@ -3808,7 +3808,7 @@ std::string AstVariableNode::format(std::string indent) {
 
 std::string AstMemoryNode::format(std::string indent) {
    std::stringstream ret;
-   ret << indent << "Mem/" << hex << this << dec << "("
+   ret << indent << "Mem/" << std::hex << this << std::dec << "("
        << ((mem_ == EffectiveAddr) ? "EffAddr" : "BytesAcc")
        << ")" << endl;
 
diff --git a/dyninstAPI/src/binaryEdit.C b/dyninstAPI/src/binaryEdit.C
index 4ead51b..98fc50b 100644
--- a/dyninstAPI/src/binaryEdit.C
+++ b/dyninstAPI/src/binaryEdit.C
@@ -526,7 +526,7 @@ bool BinaryEdit::writeFile(const std::string &newFileName)
    delayRelocation_ = false;
       relocate();
       
-      vector<Region*> oldSegs;
+      std::vector<Region*> oldSegs;
       symObj->getAllRegions(oldSegs);
 
       //Write any traps to the mutatee
@@ -753,7 +753,7 @@ bool BinaryEdit::createMemoryBackingStore(mapped_object *obj) {
     // binary so that we can store updates.
 
     Symtab *symObj = obj->parse_img()->getObject();
-    vector<Region*> regs;
+    std::vector<Region*> regs;
     symObj->getAllRegions(regs);
 
    for (unsigned i = 0; i < regs.size(); i++) {
@@ -908,7 +908,7 @@ void BinaryEdit::setupRTLibrary(std::vector<BinaryEdit *> &r)
    }
 }
 
-vector<BinaryEdit *> &BinaryEdit::rtLibrary()
+std::vector<BinaryEdit *> &BinaryEdit::rtLibrary()
 {
    return rtlib;
 }
@@ -963,7 +963,7 @@ bool BinaryEdit::usedATrap() {
 // calls to dyn_<sigaction_equivalent_name>. 
 bool BinaryEdit::replaceTrapHandler() {
 
-    vector<string> sigaction_names;
+    std::vector<std::string> sigaction_names;
     OS::get_sigaction_names(sigaction_names);
 
     pdvector<func_instance *> allFuncs;
@@ -995,7 +995,7 @@ bool BinaryEdit::replaceTrapHandler() {
                     std::string sigactName = sigaction_names[nidx];
                     for (int num_s=0; 
                          num_s <= 2; 
-                         num_s++, sigactName.append(string("_"),0,1)) {
+                         num_s++, sigactName.append(std::string("_"),0,1)) {
                         if (calleeName == sigactName) {
                             modifyCall(iblk, repfunc, func);
                             replaced = true;
@@ -1038,6 +1038,6 @@ void BinaryEdit::addTrap(Address from, Address to, codeGen &gen) {
    gen.setAddr(from);
    insnCodeGen::generateTrap(gen);
    trapMapping.addTrapMapping(from, to, true);
-   springboard_cerr << "Generated springboard trap " << hex << from << "->" << to << dec << endl;
+   springboard_cerr << "Generated springboard trap " << std::hex << from << "->" << to << std::dec << endl;
 }
 
diff --git a/dyninstAPI/src/codegen-x86.C b/dyninstAPI/src/codegen-x86.C
index bbc8f87..9eb9c91 100644
--- a/dyninstAPI/src/codegen-x86.C
+++ b/dyninstAPI/src/codegen-x86.C
@@ -859,7 +859,7 @@ bool insnCodeGen::generateMem(codeGen &gen,
 	   //The instruction accesses memory via segment registers.  Disallow.
       // That just takes all the fun out of it. Don't disallow, but still skip FS
 	   if (orig_instr.getPrefix()->getPrefix(1) == 0x64) {
-		   cerr << "Warning: insn at << uses segment regs: " << hex << (int) orig_instr.getPrefix()->getPrefix(1) << endl;
+		   cerr << "Warning: insn at << uses segment regs: " << std::hex << (int) orig_instr.getPrefix()->getPrefix(1) << endl;
          return false;
       }
    }
diff --git a/dyninstAPI/src/codegen.C b/dyninstAPI/src/codegen.C
index 1b32e2f..8ea2575 100644
--- a/dyninstAPI/src/codegen.C
+++ b/dyninstAPI/src/codegen.C
@@ -760,7 +760,7 @@ void codeGen::registerDefensivePad(block_instance *callBlock, Address padStart,
   // and a padding area post-reloc-call for
   // control flow interception purposes.
   // This is kind of hacky, btw.
-    //cerr << "Registering pad [" << hex << padStart << "," << padStart + padSize << "], for block @ " << callBlock->start() << dec << endl;
+    //cerr << "Registering pad [" << std::hex << padStart << "," << padStart + padSize << "], for block @ " << callBlock->start() << std::dec << endl;
   defensivePads_[callBlock] = Extent(padStart, padSize);
 }
 
@@ -771,19 +771,19 @@ using namespace InstructionAPI;
 std::string codeGen::format() const {
    if (!aSpace_) return "<codeGen>";
 
-   stringstream ret;
+   std::stringstream ret;
 
    Address base = (addr_ != (Address)-1) ? addr_ : 0;
    InstructionDecoder deco
       (buffer_,used(),aSpace_->getArch());
    Instruction::Ptr insn = deco.decode();
-   ret << hex;
+   ret << std::hex;
    while(insn) {
      ret << "\t" << base << ": " << insn->format(base) << " / " << *((const unsigned *)insn->ptr()) << endl;
       base += insn->size();
       insn = deco.decode();
    }
-   ret << dec;
+   ret << std::dec;
    return ret.str();
 };
    
diff --git a/dyninstAPI/src/dynProcess.C b/dyninstAPI/src/dynProcess.C
index fd3ff41..c9627b3 100644
--- a/dyninstAPI/src/dynProcess.C
+++ b/dyninstAPI/src/dynProcess.C
@@ -144,7 +144,7 @@ PCProcess *PCProcess::attachProcess(const string &progpath, int pid,
         const char *lastErrMsg = getLastErrorMsg();
         startup_printf("%s[%d]: Failed to attach process %d: %s\n",
                 __FILE__, __LINE__, pid, lastErrMsg);
-        stringstream msg;
+        std::stringstream msg;
         msg << "Failed to attach to process " << pid << ": " << lastErrMsg;
         showErrorCallback(26, msg.str());
         return NULL;
@@ -606,8 +606,8 @@ bool PCProcess::createInitialMappedObjects() {
        if ((*i) == libraries.getExecutable()) continue;
 
        startup_cerr << "Library: " << (*i)->getAbsoluteName() 
-            << hex << " / " << (*i)->getLoadAddress() 
-            << ", " << ((*i)->isSharedLib() ? "<lib>" : "<aout>") << dec << endl;
+            << std::hex << " / " << (*i)->getLoadAddress() 
+            << ", " << ((*i)->isSharedLib() ? "<lib>" : "<aout>") << std::dec << endl;
 
        mapped_object *newObj = mapped_object::createMappedObject(*i, 
                                                                  this, analysisMode_);
@@ -1251,7 +1251,7 @@ bool PCProcess::readDataSpace(const void *inTracedProcess, u_int amount,
 
     bool result = pcProc_->readMemory(inSelf, (Address)inTracedProcess, amount);
     if( !result && displayErrMsg ) {
-        stringstream msg;
+        std::stringstream msg;
         msg << "System error: unable to read " << amount << "@" 
             << Address_str((Address)inTracedProcess) << " from process data space: "
             << getLastErrorMsg() << "(pid = " << getPid() << ")";
@@ -1268,7 +1268,7 @@ bool PCProcess::readDataWord(const void *inTracedProcess, u_int amount,
     // XXX see writeDataWord above
     bool result = pcProc_->readMemory(inSelf, (Address)inTracedProcess, amount);
     if( !result && displayErrMsg ) {
-        stringstream msg;
+        std::stringstream msg;
         msg << "System error: unable to read " << amount << "@" 
             << Address_str((Address)inTracedProcess) << " from process data space: "
             << getLastErrorMsg() << "(pid = " << getPid() << ")";
@@ -1463,8 +1463,8 @@ bool PCProcess::initializeRegisterThread() {
 
 
 void PCProcess::addThread(PCThread *thread) {
-    pair<map<dynthread_t, PCThread *>::iterator, bool> result;
-    result = threadsByTid_.insert(make_pair(thread->getTid(), thread));
+    std::pair<map<dynthread_t, PCThread *>::iterator, bool> result;
+    result = threadsByTid_.insert(std::make_pair(thread->getTid(), thread));
 
     assert( result.second && "Thread already in collection of threads" );
     proccontrol_printf("%s[%d]: added thread %lu to process %d\n",
@@ -2048,7 +2048,7 @@ bool PCProcess::postIRPC_internal(void *buf,
    Address foo = addr;
    InstructionAPI::Instruction::Ptr insn = d.decode();
    while(insn) {
-      cerr << "\t" << hex << foo << ": " << insn->format(foo) << dec << endl;
+      cerr << "\t" << std::hex << foo << ": " << insn->format(foo) << std::dec << endl;
       foo += insn->size();
       insn = d.decode();
    }
@@ -2211,7 +2211,7 @@ bool PCProcess::getOverwrittenBlocks
         if (isMemoryEmulated()) {
             bool valid = false;
             boost::tie(valid,readAddr) = getMemEm()->translate(curPageAddr);
-                        cerr << "\t\t Reading from shadow page " << hex << readAddr << " instead of original " << curPageAddr << endl;
+                        cerr << "\t\t Reading from shadow page " << std::hex << readAddr << " instead of original " << curPageAddr << endl;
             assert(valid);
         }
         readTextSpace((void*)readAddr, MEM_PAGE_SIZE, memVersion);
@@ -2223,24 +2223,24 @@ bool PCProcess::getOverwrittenBlocks
                 regionStart = curPageAddr+mIdx;
             } else if (foundStart && curShadow[mIdx] == memVersion[mIdx]) {
                 foundStart = false;
-                                cerr << "\t\t Adding overwritten range " << hex << regionStart << " -> " << curPageAddr + mIdx << dec << endl;
+                                cerr << "\t\t Adding overwritten range " << std::hex << regionStart << " -> " << curPageAddr + mIdx << std::dec << endl;
 
                 overwrittenRanges.push_back(
-                    pair<Address,Address>(regionStart,curPageAddr+mIdx));
+                    std::pair<Address,Address>(regionStart,curPageAddr+mIdx));
             }
         }
         if (foundStart) {
 
             foundStart = false;
-                        cerr << "\t\t Adding overwritten range " << hex << regionStart << " -> " << curPageAddr + MEM_PAGE_SIZE << dec << endl;
+                        cerr << "\t\t Adding overwritten range " << std::hex << regionStart << " -> " << curPageAddr + MEM_PAGE_SIZE << std::dec << endl;
 
             overwrittenRanges.push_back(
-                pair<Address,Address>(regionStart,curPageAddr+MEM_PAGE_SIZE));
+                std::pair<Address,Address>(regionStart,curPageAddr+MEM_PAGE_SIZE));
         }
     }
 
     // 3. Determine which basic blocks have been overwritten
-    list<pair<Address,Address> >::const_iterator rIter = overwrittenRanges.begin();
+    list<std::pair<Address,Address> >::const_iterator rIter = overwrittenRanges.begin();
     std::list<block_instance*> curBBIs;
     while (rIter != overwrittenRanges.end()) {
         mapped_object *curObject = findObject((*rIter).first);
@@ -2266,19 +2266,19 @@ bool PCProcess::getOverwrittenBlocks
 
 // distribute the work to mapped_objects
 void PCProcess::updateCodeBytes
-    ( const list<pair<Address, Address> > &owRanges ) // input
+    ( const list<std::pair<Address, Address> > &owRanges ) // input
 {
-    std::map<mapped_object *,list<pair<Address,Address> >*> objRanges;
-    list<pair<Address,Address> >::const_iterator rIter = owRanges.begin();
+    std::map<mapped_object *,list<std::pair<Address,Address> >*> objRanges;
+    list<std::pair<Address,Address> >::const_iterator rIter = owRanges.begin();
     for (; rIter != owRanges.end(); rIter++) {
         mapped_object *obj = findObject((*rIter).first);
         if (objRanges.find(obj) == objRanges.end()) {
-            objRanges[obj] = new list<pair<Address,Address> >();
+            objRanges[obj] = new list<std::pair<Address,Address> >();
         }
-        objRanges[obj]->push_back(pair<Address,Address>(rIter->first, rIter->second));
+        objRanges[obj]->push_back(std::pair<Address,Address>(rIter->first, rIter->second));
     }
 
-    std::map<mapped_object *,list<pair<Address,Address> > *>::iterator oIter = 
+    std::map<mapped_object *,list<std::pair<Address,Address> > *>::iterator oIter = 
         objRanges.begin();
     for (; oIter != objRanges.end(); oIter++) 
     {
@@ -2658,7 +2658,7 @@ bool PCProcess::generateRequiredPatches(instPoint *callPoint,
     // To do that, we're going to:
     // 1) Forward map the entry of the ft block to
     //    its most recent relocated version (if that exists)
-    // 2) For each padding area, create a (padAddr,target) pair
+    // 2) For each padding area, create a (padAddr,target) std::pair
 
     // 3)
 
@@ -2988,7 +2988,7 @@ Address PCProcess::stopThreadCtrlTransfer (instPoint* intPoint,
         // c. The stack was tampered with and we need the (mod_pc - pc) 
         //    offset to figure out where we should be
         malware_cerr << "Looking for matches to incoming address " 
-            << hex << target << dec << endl;
+            << std::hex << target << std::dec << endl;
         std::pair<func_instance*,Address> tmp;
 
         if ( reverseDefensiveMap_.find(target,tmp) ) {
@@ -3033,8 +3033,8 @@ Address PCProcess::stopThreadCtrlTransfer (instPoint* intPoint,
                 readDataSpace((void *) (stackTOP + 4*i), 
                               sizeof(getAddressWidth()), 
                               &stackTOPVAL, false);
-		          malware_cerr << "\tSTACK[" << hex << stackTOP+4*i << "]=" 
-                             << stackTOPVAL << dec << endl;
+		          malware_cerr << "\tSTACK[" << std::hex << stackTOP+4*i << "]=" 
+                             << stackTOPVAL << std::dec << endl;
            }
 #endif
 
@@ -3060,8 +3060,8 @@ Address PCProcess::stopThreadCtrlTransfer (instPoint* intPoint,
                 readDataSpace((void *) (stackTOP + 4*i), 
                               sizeof(getAddressWidth()), 
                               &stackTOPVAL, false);
-		          malware_cerr << "\tSTACK[" << hex << stackTOP+4*i << "]=" 
-                             << stackTOPVAL << dec << endl;
+		          malware_cerr << "\tSTACK[" << std::hex << stackTOP+4*i << "]=" 
+                             << stackTOPVAL << std::dec << endl;
            }
 #endif
 
@@ -3249,7 +3249,7 @@ void PCProcess::addTrap(Address from, Address to, codeGen &gen) {
       // Oops? 
     }
 
-    installedCtrlBrkpts.insert(make_pair(from, newBreak));
+    installedCtrlBrkpts.insert(std::make_pair(from, newBreak));
     gen.invalidate();
 }
 
diff --git a/dyninstAPI/src/emit-x86.C b/dyninstAPI/src/emit-x86.C
index 7a9b88b..c803c4a 100644
--- a/dyninstAPI/src/emit-x86.C
+++ b/dyninstAPI/src/emit-x86.C
@@ -1760,7 +1760,7 @@ Register EmitterAMD64::emitCall(opCode op, codeGen &gen, const pdvector<AstNodeP
 
    // Before we generate argument code, save any register that's live across
    // the call. 
-   pdvector<pair<unsigned,int> > savedRegsToRestore;
+   pdvector<std::pair<unsigned,int> > savedRegsToRestore;
    if (inInstrumentation) {
       bitArray regsClobberedByCall = ABI::getABI(8)->getCallWrittenRegisters();
       for (int i = 0; i < gen.rs()->numGPRs(); i++) {
@@ -1786,7 +1786,7 @@ Register EmitterAMD64::emitCall(opCode op, codeGen &gen, const pdvector<AstNodeP
              reg->keptValue || // Has a kept value
              (reg->liveState == registerSlot::live)) { // needs to be saved pre-call
             regalloc_printf("%s[%d]: \tsaving reg\n", FILE__, __LINE__);
-            pair<unsigned, unsigned> regToSave;
+            std::pair<unsigned, unsigned> regToSave;
             regToSave.first = reg->number;
             
             regToSave.second = reg->refCount;
diff --git a/dyninstAPI/src/function.C b/dyninstAPI/src/function.C
index ab6940b..52119f9 100644
--- a/dyninstAPI/src/function.C
+++ b/dyninstAPI/src/function.C
@@ -1121,7 +1121,7 @@ bool func_instance::randomize(TMap* tMap, bool seeded, int seed)
         int tmp;
         if (localsRanges.find(curLB, lb, ub, tmp) && matchRanges(locals.at(counter).back()->valid(), curLoc->valid())) {
             // If there already exists a range for the current LB, update
-            localsRanges.update(lb, max(ub, curLoc->off() + curLoc->size()));
+            localsRanges.update(lb, std::max(ub, curLoc->off() + curLoc->size()));
             stackmods_printf("%s in range %d\n", curLoc->format().c_str(), counter);
             locals.at(counter).push_back(curLoc);
         } else {
@@ -1131,7 +1131,7 @@ bool func_instance::randomize(TMap* tMap, bool seeded, int seed)
             localsRanges.insert(curLoc->off(), curLoc->off() + curLoc->size(), counter);
             stackmods_printf("%s in range %d\n", curLoc->format().c_str(), counter);
             vector<StackLocation*> nextvec;
-            locals.insert(make_pair(counter, nextvec));
+            locals.insert(std::make_pair(counter, nextvec));
             locals.at(counter).push_back(curLoc);
         }
         ++iter;
@@ -1306,7 +1306,7 @@ bool func_instance::createOffsetVector_Analysis(ParseAPI::Function* func,
     Accesses* accesses = new Accesses();
     assert(accesses);
     if (::getAccesses(func, block, addr, insn, accesses)) {
-        _accessMap->insert(make_pair(addr, accesses));
+        _accessMap->insert(std::make_pair(addr, accesses));
 
         for (auto accessIter = accesses->begin(); accessIter != accesses->end(); ++accessIter) {
             StackAccess* access = (*accessIter).second;
@@ -1568,7 +1568,7 @@ void func_instance::createTMap_internal(StackMod* mod, StackLocation* loc, TMap*
                                   (off < c + (d-c))) {
                               stackmods_printf("\t\t Processing interaction with %s\n", loc->format().c_str());
                               StackLocation* tmp = new StackLocation();
-                              tMap->insert(make_pair(loc, tmp));
+                              tMap->insert(std::make_pair(loc, tmp));
                               stackmods_printf("\t\t Adding to tMap %s -> %s\n", loc->format().c_str(), tmp->format().c_str());
                           }
 
@@ -1614,7 +1614,7 @@ void func_instance::createTMap_internal(StackMod* mod, StackLocation* loc, TMap*
                                 src = loc;
                                 tmp = new StackLocation(off + (m-c), size-(off.height()-c.height()), loc->type(), false, loc->valid());
                             }
-                            auto res = tMap->insert(make_pair(src, tmp));
+                            auto res = tMap->insert(std::make_pair(src, tmp));
                             stackmods_printf("\t\t\t Adding to tMap: %s -> %s\n", loc->format().c_str(), tmp->format().c_str());
                             if (res.second) {
                                 stackmods_printf("\t\t\t\t Added.\n");
@@ -1643,7 +1643,7 @@ void func_instance::createTMap_internal(StackMod* mod, TMap* tMap)
         StackAnalysis::Height d(insertMod->high());
         StackLocation* tmpSrc = new StackLocation();
         StackLocation* tmpDest = new StackLocation(c, (d-c).height(), StackAccess::UNKNOWN, false);
-        tMap->insert(make_pair(tmpSrc, tmpDest));
+        tMap->insert(std::make_pair(tmpSrc, tmpDest));
         stackmods_printf("\t\t\t Adding to tMap: %s -> %s\n", tmpSrc->format().c_str(), tmpDest->format().c_str());
     }
 
diff --git a/dyninstAPI/src/function.h b/dyninstAPI/src/function.h
index db98727..d17f828 100644
--- a/dyninstAPI/src/function.h
+++ b/dyninstAPI/src/function.h
@@ -100,10 +100,10 @@ class func_instance : public patchTarget, public Dyninst::PatchAPI::PatchFunctio
   // this function) we make most methods passthroughs to the original
   // parsed version.
 
-  string symTabName() const { return ifunc()->symTabName(); };
-  string prettyName() const { return ifunc()->prettyName(); };
-  string typedName() const { return ifunc()->typedName(); };
-  string name() const { return symTabName(); }
+  std::string symTabName() const { return ifunc()->symTabName(); };
+  std::string prettyName() const { return ifunc()->prettyName(); };
+  std::string typedName() const { return ifunc()->typedName(); };
+  std::string name() const { return symTabName(); }
 
   SymtabAPI::Aggregate::name_iter symtab_names_begin() const 
    {
@@ -129,9 +129,9 @@ class func_instance : public patchTarget, public Dyninst::PatchAPI::PatchFunctio
    {
      return ifunc()->typed_names_end();
    }
-   //vector<string> symTabNameVector() const { return ifunc()->symTabNameVector(); }
-   //vector<string> prettyNameVector() const { return ifunc()->prettyNameVector(); }
-   //vector<string> typedNameVector() const { return ifunc()->typedNameVector(); }
+   //vector<std::string> symTabNameVector() const { return ifunc()->symTabNameVector(); }
+   //vector<std::string> prettyNameVector() const { return ifunc()->prettyNameVector(); }
+   //vector<std::string> typedNameVector() const { return ifunc()->typedNameVector(); }
 
   // Debuggering functions
   void debugPrint() const;
diff --git a/dyninstAPI/src/hybridAnalysis.h b/dyninstAPI/src/hybridAnalysis.h
index 12d0bef..9885599 100644
--- a/dyninstAPI/src/hybridAnalysis.h
+++ b/dyninstAPI/src/hybridAnalysis.h
@@ -122,7 +122,7 @@ public:
     void getCallBlocks(Dyninst::Address retAddr, 
                        func_instance *retFunc,
                        block_instance *retBlock,
-                       pair<ParseAPI::Block*, Dyninst::Address> & returningCallB, // output
+                       std::pair<ParseAPI::Block*, Dyninst::Address> & returningCallB, // output
                        set<ParseAPI::Block*> & callBlocks); // output
 
     std::map< BPatch_point* , SynchHandle* > & synchMap_pre();
diff --git a/dyninstAPI/src/hybridCallbacks.C b/dyninstAPI/src/hybridCallbacks.C
index d28349e..f22853f 100644
--- a/dyninstAPI/src/hybridCallbacks.C
+++ b/dyninstAPI/src/hybridCallbacks.C
@@ -294,7 +294,7 @@ void HybridAnalysis::signalHandlerEntryCB2(BPatch_point *point, Address excCtxtA
 }
 
 void HybridAnalysis::virtualFreeAddrCB(BPatch_point *, void *addr) {
-	cerr << "Setting virtualFree addr to " << hex << (Address) addr << dec << endl;
+	cerr << "Setting virtualFree addr to " << std::hex << (Address) addr << std::dec << endl;
 	virtualFreeAddr_ = (Address) addr;
 	return;
 }
@@ -308,7 +308,7 @@ void HybridAnalysis::virtualFreeSizeCB(BPatch_point *, void *size) {
 void HybridAnalysis::virtualFreeCB(BPatch_point *, void *t) {
 	assert(virtualFreeAddr_ != 0);
 	unsigned type = (unsigned) t;
-	cerr << "virtualFree [" << hex << virtualFreeAddr_ << "," << virtualFreeAddr_ + (unsigned) virtualFreeSize_ << "], " << (unsigned) type << dec << endl;
+	cerr << "virtualFree [" << std::hex << virtualFreeAddr_ << "," << virtualFreeAddr_ + (unsigned) virtualFreeSize_ << "], " << (unsigned) type << std::dec << endl;
 
 	Address pageSize = proc()->lowlevel_process()->getMemoryPageSize();
 
@@ -508,7 +508,7 @@ static int getPreCallPoints(ParseAPI::Block* blk,
 void HybridAnalysis::getCallBlocks(Address retAddr, 
                    func_instance *retFunc,
                    block_instance *retBlock,
-                   pair<ParseAPI::Block*, Address> & returningCallB, // output
+                   std::pair<ParseAPI::Block*, Address> & returningCallB, // output
                    set<ParseAPI::Block*> & callBlocks) // output
 {
    // find blocks at returnAddr -1 
@@ -756,7 +756,7 @@ void HybridAnalysis::badTransferCB(BPatch_point *point, void *returnValue)
         // past, but only set set returningCallB if we can be sure that 
         // that we've found a call block that actually called the function
         // we're returning from 
-        pair<Block*, Address> returningCallB((Block*)NULL,0); 
+        std::pair<Block*, Address> returningCallB((Block*)NULL,0); 
         set<Block*> callBlocks;
         getCallBlocks(returnAddr, point->llpoint()->func(), 
                       point->llpoint()->block(), returningCallB, callBlocks);
diff --git a/dyninstAPI/src/hybridInstrumentation.C b/dyninstAPI/src/hybridInstrumentation.C
index 00a7d4a..9e96fb7 100644
--- a/dyninstAPI/src/hybridInstrumentation.C
+++ b/dyninstAPI/src/hybridInstrumentation.C
@@ -342,10 +342,10 @@ bool HybridAnalysis::instrumentFunction(BPatch_function *func,
         rfIter = replacedFuncs_.find(func);
     if (replacedFuncs_.end() != rfIter) {
         malware_cerr << "Function " << func->getName() << " at " 
-            << hex << (Address)func->getBaseAddr() << "has been replaced "
+            << std::hex << (Address)func->getBaseAddr() << "has been replaced "
             << "by function " << rfIter->second->getName() << " at " 
             << (Address)rfIter->second->getBaseAddr() 
-            << " will instrument it instead" << dec << endl;
+            << " will instrument it instead" << std::dec << endl;
         func = rfIter->second;
     }
 
@@ -671,13 +671,13 @@ void HybridAnalysis::removeInstrumentation(BPatch_function *func,
         }
     }
 
-    malware_cerr << hex << "removing instrumentation from func at "<< func->getBaseAddr() << dec << endl;
+    malware_cerr << std::hex << "removing instrumentation from func at "<< func->getBaseAddr() << std::dec << endl;
     //const PatchAPI::PatchFunction::Blockset & blocks = func->lowlevel_func()->getAllBlocks();
     //for (PatchAPI::PatchFunction::Blockset::const_iterator bit = blocks.begin();
     //     bit != blocks.end();
     //     bit++)
     //{
-    //   malware_cerr << hex << "  block [" << (*bit)->start() << " " << (*bit)->end() << ")" << dec << endl;
+    //   malware_cerr << std::hex << "  block [" << (*bit)->start() << " " << (*bit)->end() << ")" << std::dec << endl;
     //}
 
     // 1. Remove elements from instrumentedFuncs
@@ -735,7 +735,7 @@ void HybridAnalysis::removeInstrumentation(BPatch_function *func,
 // Protects the code in the module
 bool HybridAnalysis::instrumentModule(BPatch_module *mod, bool useInsertionSet) 
 {
-	malware_cerr << "HybridAnalysis instrumenting mod at " << hex << (Address)mod->getBaseAddr() << dec << endl;
+	malware_cerr << "HybridAnalysis instrumenting mod at " << std::hex << (Address)mod->getBaseAddr() << std::dec << endl;
     assert(proc() && mod);
     if (false == mod->isExploratoryModeOn()) {
         return true;
diff --git a/dyninstAPI/src/hybridOverwrites.C b/dyninstAPI/src/hybridOverwrites.C
index 8a18ffe..171f713 100644
--- a/dyninstAPI/src/hybridOverwrites.C
+++ b/dyninstAPI/src/hybridOverwrites.C
@@ -230,10 +230,10 @@ bool HybridAnalysisOW::removeLoop(owLoop *loop,
         // make sure the underlying code hasn't changed
         bool changedPages = false;
         bool changedCode = false;
-        std::vector<pair<Address,int> > deadBlocks;
+        std::vector<std::pair<Address,int> > deadBlocks;
         std::vector<BPatch_function*> modFuncs;
         if (writePoint) {
-   			cerr << "Calling overwriteAnalysis with point @ " << hex << writePoint->getAddress() << dec << endl;
+   			cerr << "Calling overwriteAnalysis with point @ " << std::hex << writePoint->getAddress() << std::dec << endl;
             overwriteAnalysis(writePoint,(void*)(intptr_t)loop->getID());
         } else {
             std::set<BPatch_function *> funcsToInstrument;
@@ -1159,7 +1159,7 @@ void HybridAnalysisOW::overwriteAnalysis(BPatch_point *point, void *loopID_)
     bool changedPages = false;
     bool changedCode = false;
     std::vector<BPatch_function*> owFuncs;
-    std::vector<pair<Address,int> > deadBlocks;
+    std::vector<std::pair<Address,int> > deadBlocks;
     std::vector<BPatch_function*> newFuncs;
     std::vector<BPatch_function*> modFuncs;
     std::set<BPatch_module*> modModules;
@@ -1232,7 +1232,7 @@ void HybridAnalysisOW::overwriteAnalysis(BPatch_point *point, void *loopID_)
         // overwrite stats
         hybrid_->stats_.owCount++;
         unsigned long owBytes = 0;
-        for (vector<pair<Address,int> >::iterator bit = deadBlocks.begin();
+        for (vector<std::pair<Address,int> >::iterator bit = deadBlocks.begin();
              bit != deadBlocks.end();
              bit++)
         {
diff --git a/dyninstAPI/src/image.C b/dyninstAPI/src/image.C
index 9afbeee..32d778e 100644
--- a/dyninstAPI/src/image.C
+++ b/dyninstAPI/src/image.C
@@ -139,9 +139,9 @@ bool fileDescriptor::IsEqual(const fileDescriptor &fd) const {
     if(extract_pathname_tail(file_) == extract_pathname_tail(fd.file_)) file_match_ = true;
 #endif
 #if 0
-    cerr << hex << "Addr comparison: " << code_ << " ? " << fd.code_
+    cerr << std::hex << "Addr comparison: " << code_ << " ? " << fd.code_
          << ", " << data_ << " ? " << fd.data_ 
-         << ", " << dynamic_ << " ? " << fd.dynamic_ << dec << endl;
+         << ", " << dynamic_ << " ? " << fd.dynamic_ << std::dec << endl;
 #endif
     bool addr_match = ((code_ == fd.code_ && data_ == fd.data_) ||
                        (dynamic_ && dynamic_ == fd.dynamic_));
@@ -818,8 +818,8 @@ bool image::determineImageType()
   return true;
 }
 
-bool image::getInferiorHeaps(vector<pair<string,Address> > &codeHeaps,
-                             vector<pair<string,Address> > &dataHeaps) {
+bool image::getInferiorHeaps(vector<std::pair<string,Address> > &codeHeaps,
+                             vector<std::pair<string,Address> > &dataHeaps) {
     if ((codeHeaps_.size() == 0) &&
         (dataHeaps_.size() == 0)) return false;
 
@@ -871,7 +871,7 @@ bool image::addSymtabVariables()
        // list of inferior heaps...
        string compString = "DYNINSTstaticHeap";
        if (!var->symTabName().compare(0, compString.size(), compString)) {
-           dataHeaps_.push_back(pair<string,Address>(var->symTabName(), var->getOffset()));
+           dataHeaps_.push_back(std::pair<string,Address>(var->symTabName(), var->getOffset()));
        }
 
        exportedVariables.push_back(var);
@@ -1570,7 +1570,7 @@ parse_func *image::addFunction(Address functionEntryAddr, const char *fName)
      // list of inferior heaps...
      string compString = "DYNINSTstaticHeap";
      if (!func->symTabName().compare(0, compString.size(), compString)) {
-         codeHeaps_.push_back(pair<string, Address>(func->symTabName(), func->getOffset()));
+         codeHeaps_.push_back(std::pair<string, Address>(func->symTabName(), func->getOffset()));
      }
 
      func->addSymTabName( funcName ); 
diff --git a/dyninstAPI/src/image.h b/dyninstAPI/src/image.h
index e29e545..250e0d8 100644
--- a/dyninstAPI/src/image.h
+++ b/dyninstAPI/src/image.h
@@ -122,13 +122,13 @@ class PCProcess;
 // File descriptor information
 class fileDescriptor {
  public:
-    static string emptyString;
+    static std::string emptyString;
     // Vector requires an empty constructor
     fileDescriptor();
 
     // Some platforms have split code and data. If yours is not one of them,
     // hand in the same address for code and data.
-    fileDescriptor(string file, Address code, Address data, 
+    fileDescriptor(std::string file, Address code, Address data, 
                    bool isShared=false, Address dynamic=0) :
 #if defined(os_windows)
 		procHandle_(INVALID_HANDLE_VALUE),
@@ -145,7 +145,7 @@ class fileDescriptor {
         rawPtr_(NULL) {}
 
     // ctor for non-files
-    fileDescriptor(string file, Address code, Address data, 
+    fileDescriptor(std::string file, Address code, Address data, 
                    Address length, void* rawPtr,
                    bool isShared=false, Address dynamic=0) :
 #if defined(os_windows)
@@ -180,8 +180,8 @@ class fileDescriptor {
          return false;
      }
      
-     const string &file() const { return file_; }
-     const string &member() const { return member_; }
+     const std::string &file() const { return file_; }
+     const std::string &member() const { return member_; }
      Address code() const { return code_; }
      Address data() const { return data_; }
      bool isSharedObject() const { return shared_; }
@@ -194,7 +194,7 @@ class fileDescriptor {
      }
      void setCode(Address c) { code_ = c; }
      void setData(Address d) { data_ = d; }
-     void setMember(string member) { member_ = member; }
+     void setMember(std::string member) { member_ = member; }
      void setPid(int pid) { pid_ = pid; }
      void setIsShared(bool shared) { shared_ = shared; }
      Address length() const { return length_; } //only for non-files
@@ -216,8 +216,8 @@ private:
      HANDLE procHandle_;
      HANDLE fileHandle_;
 #endif
-     string file_;
-     string member_;
+     std::string file_;
+     std::string member_;
      Address code_;
      Address data_;
      Address dynamic_; //Used on Linux, address of dynamic section.
@@ -238,7 +238,7 @@ class image_variable {
 
     Address getOffset() const;
 
-    string symTabName() const { return var_->getFirstSymbol()->getMangledName(); }
+    std::string symTabName() const { return var_->getFirstSymbol()->getMangledName(); }
     SymtabAPI::Aggregate::name_iter symtab_names_begin() const;
     SymtabAPI::Aggregate::name_iter symtab_names_end() const;
     SymtabAPI::Aggregate::name_iter pretty_names_begin() const;
@@ -311,7 +311,7 @@ class image : public codeRange {
    int destroy();
  public:
    // find the named module  
-   pdmodule *findModule(const string &name, bool wildcard = false);
+   pdmodule *findModule(const std::string &name, bool wildcard = false);
 
    // Find the vector of functions associated with a (demangled) name
    // Returns internal pointer, so label as const
@@ -354,9 +354,9 @@ class image : public codeRange {
 
    // data member access
 
-   string file() const {return desc_.file();}
-   string name() const { return name_;}
-   string pathname() const { return pathname_; }
+   std::string file() const {return desc_.file();}
+   std::string name() const { return name_;}
+   std::string pathname() const { return pathname_; }
    const fileDescriptor &desc() const { return desc_; }
    Address imageOffset() const { return imageOffset_;}
    Address dataOffset() const { return dataOffset_;}
@@ -398,7 +398,7 @@ class image : public codeRange {
    // element removal
 
    bool hasNewBlocks() const { return 0 < newBlocks_.size(); }
-   const vector<parse_block*> & getNewBlocks() const;
+   const std::vector<parse_block*> & getNewBlocks() const;
    void clearNewBlocks();
    // callback that updates our view the binary's raw code bytes
    void register_codeBytesUpdateCB(void *cb_arg0)
@@ -412,10 +412,10 @@ class image : public codeRange {
    const pdvector<image_variable *> &getExportedVariables() const;
    const pdvector<image_variable *> &getCreatedVariables();
 
-   bool getInferiorHeaps(vector<pair<string, Address> > &codeHeaps,
-                         vector<pair<string, Address> > &dataHeaps);
+   bool getInferiorHeaps(std::vector<std::pair<std::string, Address> > &codeHeaps,
+                         std::vector<std::pair<std::string, Address> > &dataHeaps);
 
-   bool getModules(vector<pdmodule *> &mods);
+   bool getModules(std::vector<pdmodule *> &mods);
 
     int getNextBlockID() { return nextBlockID_++; }
 
@@ -436,9 +436,9 @@ class image : public codeRange {
 
 
  private:
-   void findModByAddr (const SymtabAPI::Symbol *lookUp, vector<SymtabAPI::Symbol *> &mods,
-                       string &modName, Address &modAddr, 
-                       const string &defName);
+   void findModByAddr (const SymtabAPI::Symbol *lookUp, std::vector<SymtabAPI::Symbol *> &mods,
+                       std::string &modName, Address &modAddr, 
+                       const std::string &defName);
 
    //
    //  ****  PRIVATE MEMBERS FUNCTIONS  ****
@@ -470,8 +470,8 @@ class image : public codeRange {
    //
  private:
    fileDescriptor desc_; /* file descriptor (includes name) */
-   string name_;		 /* filename part of file, no slashes */
-   string pathname_;      /* file name with path */
+   std::string name_;		 /* filename part of file, no slashes */
+   std::string pathname_;      /* file name with path */
 
    Address imageOffset_;
    unsigned imageLen_;
@@ -525,8 +525,8 @@ class image : public codeRange {
    //  it may sometimes be necessary to do a linear sort
    //  through excludedMods if searching for a module which
    //  was excluded....
-   dyn_hash_map <string, pdmodule *> modsByFileName;
-   dyn_hash_map <string, pdmodule*> modsByFullName;
+   dyn_hash_map <std::string, pdmodule *> modsByFileName;
+   dyn_hash_map <std::string, pdmodule*> modsByFullName;
 
    // "Function" symbol names that are PLT entries or the equivalent
    // FIXME remove
@@ -534,11 +534,11 @@ class image : public codeRange {
 
    std::unordered_map <Address, image_variable *> varsByAddr;
 
-   vector<pair<string, Address> > codeHeaps_;
-   vector<pair<string, Address> > dataHeaps_;
+   std::vector<std::pair<std::string, Address> > codeHeaps_;
+   std::vector<std::pair<std::string, Address> > dataHeaps_;
 
    // new element tracking
-   vector<parse_block*> newBlocks_;
+   std::vector<parse_block*> newBlocks_;
    bool trackNewBlocks_;
 
    int refCount;
@@ -576,8 +576,8 @@ class pdmodule {
    bool findFunctionByPretty (const std::string &name,
                               pdvector<parse_func *> &found);
    void dumpMangled(std::string &prefix) const;
-   const string &fileName() const;
-   const string &fullName() const;
+   const std::string &fileName() const;
+   const std::string &fullName() const;
    SymtabAPI::supportedLanguages language() const;
    Address addr() const;
    bool isShared() const;
diff --git a/dyninstAPI/src/inst.C b/dyninstAPI/src/inst.C
index bf9fdf6..02b2214 100644
--- a/dyninstAPI/src/inst.C
+++ b/dyninstAPI/src/inst.C
@@ -58,7 +58,7 @@ std::map<std::string, unsigned> primitiveCosts;
 
 unsigned getPrimitiveCost(const std::string &name)
 {
-   std::map<string, unsigned>::iterator iter = primitiveCosts.find(name);
+   std::map<std::string, unsigned>::iterator iter = primitiveCosts.find(name);
    if (iter != primitiveCosts.end()) return iter->second;
    return 1;
 }
diff --git a/dyninstAPI/src/instPoint.C b/dyninstAPI/src/instPoint.C
index e638668..2771e51 100644
--- a/dyninstAPI/src/instPoint.C
+++ b/dyninstAPI/src/instPoint.C
@@ -152,7 +152,7 @@ instPoint::instPoint(Type          t,
 
 
 // If there is a logical "pair" (e.g., before/after) of instPoints return them.
-// The return result is a pair of <before, after>
+// The return result is a std::pair of <before, after>
 std::pair<instPoint *, instPoint *> instPoint::getInstpointPair(instPoint *i) {
    switch(i->type()) {
       case None:
@@ -378,7 +378,7 @@ Address instPoint::addr_compat() const {
 }
 
 std::string instPoint::format() const {
-   stringstream ret;
+   std::stringstream ret;
    ret << "iP(";
    switch(type_) {
       case FuncEntry:
@@ -416,13 +416,13 @@ std::string instPoint::format() const {
      ret << ", Func(" << func()->name() << ")";
    }
    if (block()) {
-     ret << ", Block(" << hex << block()->start() << dec << ")";
+     ret << ", Block(" << std::hex << block()->start() << std::dec << ")";
    }
    if (edge()) {
       ret << ", Edge";
    }
    if (addr_) {
-      ret << ", Addr(" << hex << addr_ << dec << ")";
+      ret << ", Addr(" << std::hex << addr_ << std::dec << ")";
    }
    if (insn_) {
       ret << ", Insn(" << insn_->format() << ")";
diff --git a/dyninstAPI/src/mapped_module.C b/dyninstAPI/src/mapped_module.C
index 00f8ef7..b98ab7b 100644
--- a/dyninstAPI/src/mapped_module.C
+++ b/dyninstAPI/src/mapped_module.C
@@ -130,12 +130,12 @@ void mapped_module::remove(func_instance *func)
    assert(0 && "Tried to remove function that's not in the module");
 }
 
-const string &mapped_module::fileName() const 
+const std::string &mapped_module::fileName() const 
 {
    return pmod()->fileName(); 
 }
 
-const string &mapped_module::fullName() const 
+const std::string &mapped_module::fullName() const 
 {
    return pmod()->fullName(); 
 }
diff --git a/dyninstAPI/src/mapped_module.h b/dyninstAPI/src/mapped_module.h
index 7ce6c4e..a0c2eb0 100644
--- a/dyninstAPI/src/mapped_module.h
+++ b/dyninstAPI/src/mapped_module.h
@@ -65,8 +65,8 @@ class mapped_module {
       mapped_object *obj() const;
       pdmodule *pmod() const;
 
-      const string &fileName() const;
-      const string &fullName() const;
+      const std::string &fileName() const;
+      const std::string &fullName() const;
 
       AddressSpace *proc() const;
 
diff --git a/dyninstAPI/src/mapped_object.C b/dyninstAPI/src/mapped_object.C
index 893068a..128bbaa 100644
--- a/dyninstAPI/src/mapped_object.C
+++ b/dyninstAPI/src/mapped_object.C
@@ -359,7 +359,7 @@ bool mapped_object::analyze()
   return true;
 }
 
-mapped_module *mapped_object::findModule(string m_name, bool wildcard)
+mapped_module *mapped_object::findModule(std::string m_name, bool wildcard)
 {
    parsing_printf("findModule for %s (substr match %d)\n",
          m_name.c_str(), wildcard);
@@ -785,7 +785,7 @@ void mapped_object::addVariable(int_variable *var) {
   for (auto pretty_iter = var->pretty_names_begin();
          pretty_iter != var->pretty_names_end();
          pretty_iter++) {
-        string pretty_name = *pretty_iter;
+        std::string pretty_name = *pretty_iter;
         pdvector<int_variable *> *varsByPrettyEntry = NULL;
 
         // Ensure a vector exists
@@ -811,10 +811,10 @@ void mapped_object::addVariable(int_variable *var) {
     for (auto symtab_iter = var->symtab_names_begin();
          symtab_iter != var->symtab_names_end();
          symtab_iter++) {
-      string symtab_name = *symtab_iter;
+      std::string symtab_name = *symtab_iter;
       pdvector<int_variable *> *varsBySymTabEntry = NULL;
 
-        // Ensure a vector exist
+        // Ensure a std::vector exist
         auto iter = allVarsByMangledName.find(symtab_name);
         if (iter == allVarsByMangledName.end()) {
            varsBySymTabEntry = new std::vector<int_variable *>;
@@ -868,7 +868,7 @@ const std::string mapped_object::debugString() const
 
 // Search an object for heapage
 bool mapped_object::getInfHeapList(pdvector<heapDescriptor> &infHeaps) {
-    vector<pair<string,Address> > foundHeaps;
+    std::vector<std::pair<std::string,Address> > foundHeaps;
 
     getInferiorHeaps(foundHeaps);
 
@@ -946,7 +946,7 @@ unsigned mapped_object::memoryEnd()
         return memEnd_;
     }
     memEnd_ = 0;
-    vector<SymtabAPI::Region*> regs;
+    std::vector<SymtabAPI::Region*> regs;
     parse_img()->getObject()->getMappedRegions(regs);
     for (unsigned ridx=0; ridx < regs.size(); ridx++) {
         if (memEnd_ < regs[ridx]->getMemOffset() + regs[ridx]->getMemSize()) {
@@ -961,10 +961,10 @@ unsigned mapped_object::memoryEnd()
 // This gets called once per image. Poke through to the internals;
 // all we care about, amusingly, is symbol table information.
 
-void mapped_object::getInferiorHeaps(vector<pair<string, Address> > &foundHeaps)
+void mapped_object::getInferiorHeaps(std::vector<std::pair<std::string, Address> > &foundHeaps)
 {
-    vector<pair<string, Address> > code_heaps;
-    vector<pair<string, Address> > data_heaps;
+    std::vector<std::pair<std::string, Address> > code_heaps;
+    std::vector<std::pair<std::string, Address> > data_heaps;
 
     if (!parse_img()->getInferiorHeaps(code_heaps, data_heaps)) {
         return;
@@ -973,11 +973,11 @@ void mapped_object::getInferiorHeaps(vector<pair<string, Address> > &foundHeaps)
 
     // We have a bunch of offsets, now add in the base addresses
     for (unsigned i = 0; i < code_heaps.size(); i++) {
-		foundHeaps.push_back(pair<string,Address>(code_heaps[i].first,
+		foundHeaps.push_back(std::pair<std::string,Address>(code_heaps[i].first,
                                                   code_heaps[i].second + codeBase()));
     }
     for (unsigned i = 0; i < data_heaps.size(); i++) {
-        foundHeaps.push_back(pair<string,Address>(data_heaps[i].first,
+        foundHeaps.push_back(std::pair<std::string,Address>(data_heaps[i].first,
                                                   data_heaps[i].second + dataBase()));
     }
 }
@@ -1110,7 +1110,7 @@ void mapped_object::findFuncsByRange(Address startAddr,
  *
  * A true return value means that new functions were parsed
 */
-bool mapped_object::parseNewFunctions(vector<Address> &funcEntryAddrs)
+bool mapped_object::parseNewFunctions(std::vector<Address> &funcEntryAddrs)
 {
 
     bool reparsedObject = false;
@@ -1126,7 +1126,7 @@ bool mapped_object::parseNewFunctions(vector<Address> &funcEntryAddrs)
     assert(!parse_img()->hasNewBlocks());
 
     // update regions if necessary, check that functions not parsed already
-    vector<Address>::iterator curEntry = funcEntryAddrs.begin();
+    std::vector<Address>::iterator curEntry = funcEntryAddrs.begin();
     while (curEntry != funcEntryAddrs.end()) {
         Address entryOffset = (*curEntry)-baseAddress;
         reg = parse_img()->getObject()->findEnclosingRegion(entryOffset);
@@ -1197,7 +1197,7 @@ bool mapped_object::parseNewEdges(const std::vector<edgeStub> &stubs)
     using namespace SymtabAPI;
     using namespace ParseAPI;
 
-    vector<ParseAPI::CodeObject::NewEdgeToParse> edgesInThisObject;
+    std::vector<ParseAPI::CodeObject::NewEdgeToParse> edgesInThisObject;
 
 /* 0. Make sure memory for the target is up to date */
 
@@ -1292,8 +1292,8 @@ bool mapped_object::parseNewEdges(const std::vector<edgeStub> &stubs)
 	parse_img()->codeObject()->parseNewEdges(edgesInThisObject);
 
     // build list of potentially modified functions
-    vector<ParseAPI::Function*> modIFuncs;
-    vector<func_instance*> modFuncs;
+    std::vector<ParseAPI::Function*> modIFuncs;
+    std::vector<func_instance*> modFuncs;
     for(unsigned sidx=0; sidx < stubs.size(); sidx++) {
         if (stubs[sidx].src != NULL) {
             stubs[sidx].src->llb()->getFuncs(modIFuncs);
@@ -1423,7 +1423,7 @@ void mapped_object::expandCodeBytes(SymtabAPI::Region *reg)
 // 1. use other update functions to update non-code areas of mapped files,
 //    expanding them if we overwrote into unmapped areas
 // 2. copy overwritten regions into the mapped objects
-void mapped_object::updateCodeBytes(const list<pair<Address,Address> > &owRanges)
+void mapped_object::updateCodeBytes(const list<std::pair<Address,Address> > &owRanges)
 {
     bool memEmulation = proc()->isMemoryEmulated();
 // 1. use other update functions to update non-code areas of mapped files,
@@ -1433,7 +1433,7 @@ void mapped_object::updateCodeBytes(const list<pair<Address,Address> > &owRanges
     Address baseAddress = codeBase();
 
     // figure out which regions need expansion and which need updating
-    list<pair<Address,Address> >::const_iterator rIter = owRanges.begin();
+    list<std::pair<Address,Address> >::const_iterator rIter = owRanges.begin();
     for(; rIter != owRanges.end(); rIter++) {
         Address lastChangeOffset = (*rIter).second -1 -baseAddress;
         Region *curReg = parse_img()->getObject()->findEnclosingRegion
@@ -1585,7 +1585,7 @@ void mapped_object::updateCodeBytes(SymtabAPI::Region * symReg)
     Address regEnd = base + regStart + symReg->getDiskSize();
     for (; protPages_.end() == protPages_.find(curPage)  && curPage < regEnd;
          curPage += page_size) {};
-    for (map<Address,WriteableStatus>::iterator pit = protPages_.find(curPage);
+    for (std::map<Address,WriteableStatus>::iterator pit = protPages_.find(curPage);
          pit != protPages_.end() && pit->first < regEnd;
          pit++)
     {
@@ -1871,13 +1871,13 @@ void mapped_object::removeEmptyPages()
 {
     // get all pages currently containing code from the mapped modules
     set<Address> curPages;
-    vector<Address> emptyPages;
-    const vector<mapped_module*> & mods = getModules();
+    std::vector<Address> emptyPages;
+    const std::vector<mapped_module*> & mods = getModules();
     for (unsigned midx=0; midx < mods.size(); midx++) {
         mods[midx]->getAnalyzedCodePages(curPages);
     }
     // find entries in protPages_ that aren't in curPages, add to emptyPages
-    for (map<Address,WriteableStatus>::iterator pit= protPages_.begin();
+    for (std::map<Address,WriteableStatus>::iterator pit= protPages_.begin();
          pit != protPages_.end();
          pit++)
     {
@@ -1944,7 +1944,7 @@ bool mapped_object::isExploratoryModeOn()
 
 void mapped_object::addProtectedPage(Address pageAddr)
 {
-    map<Address,WriteableStatus>::iterator iter = protPages_.find(pageAddr);
+    std::map<Address,WriteableStatus>::iterator iter = protPages_.find(pageAddr);
     if (protPages_.end() == iter) {
         protPages_[pageAddr] = PROTECTED;
     }
@@ -1955,7 +1955,7 @@ void mapped_object::addProtectedPage(Address pageAddr)
 
 void mapped_object::removeProtectedPage(Address pageAddr)
 {
-    map<Address,WriteableStatus>::iterator iter = protPages_.find(pageAddr);
+    std::map<Address,WriteableStatus>::iterator iter = protPages_.find(pageAddr);
     if (iter == protPages_.end()) {
         // sanity check, make sure there isn't any code on the page, in which
         // case we're unprotecting a page that was originally set to be writeable
@@ -2015,7 +2015,7 @@ bool mapped_object::isEmulInsn(Address insnAddr)
 void mapped_object::setEmulInsnVal(Address insnAddr, void * val)
 {
     assert(emulInsns_.end() != emulInsns_.find(insnAddr));
-    emulInsns_[insnAddr] = pair<Register,void*>(emulInsns_[insnAddr].first,val);
+    emulInsns_[insnAddr] = std::pair<Register,void*>(emulInsns_[insnAddr].first,val);
 }
 
 Register mapped_object::getEmulInsnReg(Address insnAddr)
@@ -2026,7 +2026,7 @@ Register mapped_object::getEmulInsnReg(Address insnAddr)
 
 void mapped_object::addEmulInsn(Address insnAddr, Register effectiveAddrReg)
 {
-    emulInsns_[insnAddr] = pair<Register,void*>(effectiveAddrReg,(void *)0);
+    emulInsns_[insnAddr] = std::pair<Register,void*>(effectiveAddrReg,(void *)0);
 }
 
 std::string mapped_object::getCalleeName(block_instance *b) {
@@ -2034,7 +2034,7 @@ std::string mapped_object::getCalleeName(block_instance *b) {
    if (iter != calleeNames_.end()) return iter->second;
 
 #if defined(os_windows)
-   string calleeName;
+   std::string calleeName;
    if (parse_img()->codeObject()->isIATcall(b->last() - codeBase(), calleeName)) {
       setCalleeName(b, calleeName);
       return calleeName;
@@ -2084,10 +2084,10 @@ block_instance *mapped_object::findOneBlockByAddr(const Address addr) {
 void mapped_object::splitBlock(block_instance * b1, 
                                block_instance * b2) 
 {
-    // fix block mappings in: map<block_instance *, std::string> calleeNames_
-    map<block_instance *, std::string>::iterator nit = calleeNames_.find(b1);
+    // fix block mappings in: std::map<block_instance *, std::string> calleeNames_
+    std::map<block_instance *, std::string>::iterator nit = calleeNames_.find(b1);
     if (calleeNames_.end() != nit) {
-        string name = nit->second;
+        std::string name = nit->second;
         calleeNames_.erase(nit);
         calleeNames_[b2] = name;
     }
@@ -2114,7 +2114,7 @@ void mapped_object::setCallee(const block_instance *b, func_instance *f) {
 
 void mapped_object::replacePLTStub(SymtabAPI::Symbol *sym, func_instance *orig, Address newAddr) {
    // Let's play relocation games...
-   vector<SymtabAPI::relocationEntry> fbt;
+   std::vector<SymtabAPI::relocationEntry> fbt;
    bool ok = parse_img()->getObject()->getFuncBindingTable(fbt);
    if(!ok) return;
    
@@ -2126,7 +2126,7 @@ void mapped_object::replacePLTStub(SymtabAPI::Symbol *sym, func_instance *orig,
    }
 }
 
-string mapped_object::fileName() const { 
+std::string mapped_object::fileName() const { 
   return parse_img()->getObject()->name();
   
 }
diff --git a/dyninstAPI/src/mapped_object.h b/dyninstAPI/src/mapped_object.h
index 02fc05e..92692e9 100644
--- a/dyninstAPI/src/mapped_object.h
+++ b/dyninstAPI/src/mapped_object.h
@@ -60,9 +60,9 @@ class int_symbol {
 
     Address getAddr() const { return addr_; }
     unsigned getSize() const { return sym_->getSize(); }
-    string symTabName() const { return sym_->getMangledName(); }
-    string prettyName() const { return sym_->getPrettyName(); }
-    string typedName() const { return sym_->getTypedName(); }
+    std::string symTabName() const { return sym_->getMangledName(); }
+    std::string prettyName() const { return sym_->getPrettyName(); }
+    std::string typedName() const { return sym_->getTypedName(); }
     const SymtabAPI::Symbol *sym() const { return sym_; }
 
  private:
@@ -85,14 +85,14 @@ class int_variable {
 
     Address getAddress() const { return addr_; }
     // Can variables have multiple names?
-    string symTabName() const;
+    std::string symTabName() const;
     SymtabAPI::Aggregate::name_iter pretty_names_begin() const;
     SymtabAPI::Aggregate::name_iter pretty_names_end() const;
     SymtabAPI::Aggregate::name_iter symtab_names_begin() const;
     SymtabAPI::Aggregate::name_iter symtab_names_end() const;
     
-    //const vector<string>& prettyNameVector() const;
-    //const vector<string>& symTabNameVector() const;
+    //const std::vector<std::string>& prettyNameVector() const;
+    //const std::vector<std::string>& symTabNameVector() const;
     mapped_module *mod() const { return mod_; };
     //AddressSpace *as() const { return mod()->proc(); }
     const image_variable *ivar() const { return ivar_; }
@@ -170,8 +170,8 @@ class mapped_object : public codeRange, public Dyninst::PatchAPI::DynObject {
 
     const fileDescriptor &getFileDesc() const { return desc_; }
     // Full name, including path
-    const string &fullName() const { return fullName_; }
-    string fileName() const;
+    const std::string &fullName() const { return fullName_; }
+    std::string fileName() const;
     Address codeAbs() const;
     Address codeBase() const { return codeBase_; }
     Address imageOffset() const { return parse_img()->imageOffset(); }
@@ -209,7 +209,7 @@ class mapped_object : public codeRange, public Dyninst::PatchAPI::DynObject {
 
     AddressSpace *proc() const;
 
-    mapped_module *findModule(string m_name, bool wildcard = false);
+    mapped_module *findModule(std::string m_name, bool wildcard = false);
     mapped_module *findModule(pdmodule *mod);
 
     mapped_module *getDefaultModule();
@@ -218,7 +218,7 @@ class mapped_object : public codeRange, public Dyninst::PatchAPI::DynObject {
     func_instance *findFuncByEntry(const block_instance *blk);
 
     bool getInfHeapList(pdvector<heapDescriptor> &infHeaps);
-    void getInferiorHeaps(vector<pair<string, Address> > &infHeaps);
+    void getInferiorHeaps(std::vector<std::pair<std::string, Address> > &infHeaps);
 
     bool findFuncsByAddr(const Address addr, std::set<func_instance *> &funcs);
     bool findBlocksByAddr(const Address addr, std::set<block_instance *> &blocks);
@@ -331,8 +331,8 @@ public:
     //
     fileDescriptor desc_; // full file descriptor
 
-    string  fullName_;	// full file name of the shared object
-    string  fileName_; // name of shared object as it should be identified
+    std::string  fullName_;	// full file name of the shared object
+    std::string  fileName_; // name of shared object as it should be identified
 			//  in mdl, e.g. as used for "exclude"....
     // Address   codeBase_; // The OS offset where the text segment is loaded;
     // there is a corresponding codeOffset_ in the image class.
diff --git a/dyninstAPI/src/parse-cfg.h b/dyninstAPI/src/parse-cfg.h
index 3d3a3f5..6d3ab1b 100644
--- a/dyninstAPI/src/parse-cfg.h
+++ b/dyninstAPI/src/parse-cfg.h
@@ -267,13 +267,13 @@ class parse_func : public ParseAPI::Function
      return func_->typed_names_end();
    }
    
-   /*   vector<string> symTabNameVector() const {
+   /*   vector<std::string> symTabNameVector() const {
        return func_->getAllMangledNames();
    }
-   vector<string> prettyNameVector() const {
+   vector<std::string> prettyNameVector() const {
        return func_->getAllPrettyNames();
    }
-   vector<string> typedNameVector() const {
+   vector<std::string> typedNameVector() const {
        return func_->getAllTypedNames();
        }*/
    void copyNames(parse_func *duplicate);
diff --git a/dyninstAPI/src/parse-x86.C b/dyninstAPI/src/parse-x86.C
index 7eecda5..308a2c8 100644
--- a/dyninstAPI/src/parse-x86.C
+++ b/dyninstAPI/src/parse-x86.C
@@ -331,9 +331,9 @@ bool BinaryEdit::doStaticBinarySpecialCases() {
       assert(dyninstIrelHandler);
       assert(irs_found);
       assert(ire_found);
-      std::vector<std::pair<int_symbol *, string> > tmp;
-      tmp.push_back(make_pair(&irelStart, SYMTAB_IREL_START));
-      tmp.push_back(make_pair(&irelEnd, SYMTAB_IREL_END));
+      std::vector<std::pair<int_symbol *, std::string> > tmp;
+      tmp.push_back(std::make_pair(&irelStart, SYMTAB_IREL_START));
+      tmp.push_back(std::make_pair(&irelEnd, SYMTAB_IREL_END));
       if (!replaceHandler(globalIrelHandler, dyninstIrelHandler, tmp)) {
 	return false;
       }
diff --git a/dyninstAPI/src/pcEventHandler.C b/dyninstAPI/src/pcEventHandler.C
index 349d7d8..0acbcfc 100644
--- a/dyninstAPI/src/pcEventHandler.C
+++ b/dyninstAPI/src/pcEventHandler.C
@@ -553,14 +553,14 @@ bool PCEventHandler::handleSignal(EventSignal::const_ptr ev, PCProcess *evProc)
         // User specifies the action, defaults to core dump
         // (which corresponds to standard Dyninst behavior)
         if(dyn_debug_crash_debugger) {
-            if( string(dyn_debug_crash_debugger).find("gdb") != string::npos ) {
+            if( std::string(dyn_debug_crash_debugger).find("gdb") != std::string::npos ) {
                 evProc->launchDebugger();
 
                 // If for whatever reason this fails, fall back on sleep
                 dyn_debug_crash_debugger = const_cast<char *>("sleep");
             }
 
-            if( string(dyn_debug_crash_debugger) == string("sleep") ) {
+            if( std::string(dyn_debug_crash_debugger) == std::string("sleep") ) {
                 static volatile int spin = 1;
                 while(spin) sleep(1);
             }
diff --git a/dyninstAPI/src/pcEventMuxer.C b/dyninstAPI/src/pcEventMuxer.C
index 154ccf3..bb00754 100644
--- a/dyninstAPI/src/pcEventMuxer.C
+++ b/dyninstAPI/src/pcEventMuxer.C
@@ -261,7 +261,7 @@ PCEventMuxer::cb_ret_t PCEventMuxer::signalCallback(EventPtr ev) {
     ProcControlAPI::RegisterPool regs;
     evSignal->getThread()->getAllRegisters(regs);
     for (ProcControlAPI::RegisterPool::iterator iter = regs.begin(); iter != regs.end(); ++iter) {
-      cerr << "\t Reg " << (*iter).first.name() << ": " << hex << (*iter).second << dec << endl;
+      cerr << "\t Reg " << (*iter).first.name() << ": " << std::hex << (*iter).second << std::dec << endl;
       if ((*iter).first.isStackPointer()) {
 	esp = (*iter).second;
       }
@@ -284,7 +284,7 @@ PCEventMuxer::cb_ret_t PCEventMuxer::signalCallback(EventPtr ev) {
 			     4, 
 			     &tmp,
 			     false);
-      cerr << "Stack " << hex << esp + (i*4) << ": " << tmp << dec << endl;
+      cerr << "Stack " << std::hex << esp + (i*4) << ": " << tmp << std::dec << endl;
     }
     
     unsigned disass[1024];
@@ -294,7 +294,7 @@ PCEventMuxer::cb_ret_t PCEventMuxer::signalCallback(EventPtr ev) {
     InstructionDecoder deco(disass,size,process->getArch());
     Instruction::Ptr insn = deco.decode();
     while(insn) {
-      cerr << "\t" << hex << base << ": " << insn->format(base) << dec << endl;
+      cerr << "\t" << std::hex << base << ": " << insn->format(base) << std::dec << endl;
       base += insn->size();
       insn = deco.decode();
     }
diff --git a/dyninstAPI/src/unix.C b/dyninstAPI/src/unix.C
index 33e339b..1e1c151 100644
--- a/dyninstAPI/src/unix.C
+++ b/dyninstAPI/src/unix.C
@@ -65,8 +65,8 @@ bool OS::executableExists(const std::string &file)
 
 void OS::get_sigaction_names(std::vector<std::string> &names)
 {
-   names.push_back(string("sigaction"));
-   names.push_back(string("signal"));
+   names.push_back("sigaction");
+   names.push_back("signal");
 }
 
 
@@ -402,7 +402,7 @@ bool PCProcess::setEnvPreload(std::vector<std::string> &envp, std::string fileNa
 }
 
 
-bool PCProcess::getExecFileDescriptor(string filename,
+bool PCProcess::getExecFileDescriptor(std::string filename,
         bool, fileDescriptor &desc)
 {
    Address base = 0;
@@ -574,7 +574,7 @@ mapped_object *BinaryEdit::openResolvedLibraryName(std::string filename,
                                                                    mgr(), patcher(), (*member_it)->memberName());
 
                             if (temp && temp->getAddressWidth() == getAddressWidth()) {
-                                std::string mapName = *pathIter + string(":") +
+                                std::string mapName = *pathIter + ":" +
                                     (*member_it)->memberName();
                                 retMap.insert(std::make_pair(mapName, temp));
                             }else{
diff --git a/dyninstAPI/src/variable.C b/dyninstAPI/src/variable.C
index 69c3d96..2dc3f6f 100644
--- a/dyninstAPI/src/variable.C
+++ b/dyninstAPI/src/variable.C
@@ -125,7 +125,7 @@ SymtabAPI::Aggregate::name_iter int_variable::pretty_names_end() const
   return ivar_->pretty_names_end();
 }
 
-string int_variable::symTabName() const 
+std::string int_variable::symTabName() const 
 {
    return ivar_->symTabName();
 }
diff --git a/parseAPI/h/GraphAdapter.h b/parseAPI/h/GraphAdapter.h
index 384740f..2d2b732 100644
--- a/parseAPI/h/GraphAdapter.h
+++ b/parseAPI/h/GraphAdapter.h
@@ -6,7 +6,6 @@
 
 using namespace Dyninst;
 using namespace ParseAPI;
-using namespace std;
 
 namespace boost
 {
diff --git a/parseAPI/h/Location.h b/parseAPI/h/Location.h
index 0880dd0..8651ed8 100644
--- a/parseAPI/h/Location.h
+++ b/parseAPI/h/Location.h
@@ -39,7 +39,6 @@
 #include "Instruction.h"
 
 #include <string>
-using namespace std;
 
 namespace Dyninst{
 namespace ParseAPI{
diff --git a/symtabAPI/h/Archive.h b/symtabAPI/h/Archive.h
index 3ade396..2e33790 100644
--- a/symtabAPI/h/Archive.h
+++ b/symtabAPI/h/Archive.h
@@ -31,8 +31,6 @@
 #ifndef __ARCHIVE_H__
 #define __ARCHIVE_H__
  
-using namespace std;
-
 class MappedFile;
 
 namespace Dyninst{
@@ -46,7 +44,7 @@ class Symtab;
 class SYMTAB_EXPORT ArchiveMember {
     public:
         ArchiveMember() : name_(""), offset_(0), member_(NULL) {}
-        ArchiveMember(const string name, const Offset offset,
+        ArchiveMember(const std::string name, const Offset offset,
                 Symtab * img = NULL) :
             name_(name), 
             offset_(offset), 
@@ -60,37 +58,37 @@ class SYMTAB_EXPORT ArchiveMember {
             }
         }
 
-        const string& getName()  { return name_; }
+        const std::string& getName()  { return name_; }
         Offset getOffset() { return offset_; }
         Symtab * getSymtab() { return member_; }
         void setSymtab(Symtab *img) { member_ = img; }
 
     private:
-        const string name_;
+        const std::string name_;
         Offset offset_;
         Symtab *member_;
 };
 
 class SYMTAB_EXPORT Archive : public AnnotatableSparse {
    public:
-      static bool openArchive(Archive *&img, string filename);
+      static bool openArchive(Archive *&img, std::string filename);
       static bool openArchive(Archive *&img, char *mem_image, size_t image_size);
       static SymtabError getLastError();
-      static string printError(SymtabError err);
+      static std::string printError(SymtabError err);
 
       ~Archive();
-      bool getMember(Symtab *&img, string& member_name);
+      bool getMember(Symtab *&img, std::string& member_name);
       bool getMemberByOffset(Symtab *&img, Offset memberOffset);
-      bool getMemberByGlobalSymbol(Symtab *&img, string& symbol_name);
-      bool getAllMembers(vector<Symtab *> &members);
-      bool isMemberInArchive(string& member_name);
-      bool findMemberWithDefinition(Symtab *&obj, string& name);
+      bool getMemberByGlobalSymbol(Symtab *&img, std::string& symbol_name);
+      bool getAllMembers(std::vector<Symtab *> &members);
+      bool isMemberInArchive(std::string& member_name);
+      bool findMemberWithDefinition(Symtab *&obj, std::string& name);
       std::string name();
 
-      bool getMembersBySymbol(string name, std::vector<Symtab *> &matches);
+      bool getMembersBySymbol(std::string name, std::vector<Symtab *> &matches);
 
    private:
-      Archive(string &filename, bool &err);
+      Archive(std::string &filename, bool &err);
       Archive(char *mem_image, size_t image_size, bool &err);
 
       /**
@@ -116,16 +114,16 @@ class SYMTAB_EXPORT Archive : public AnnotatableSparse {
       //For ELF the elf pointer for the archive
       void *basePtr;
 
-      dyn_hash_map<string, ArchiveMember *> membersByName;
+      dyn_hash_map<std::string, ArchiveMember *> membersByName;
       dyn_hash_map<Offset, ArchiveMember *> membersByOffset;
-      std::multimap<string, ArchiveMember *> membersBySymbol;
+      std::multimap<std::string, ArchiveMember *> membersBySymbol;
 
       // The symbol table is lazily parsed
       bool symbolTableParsed;
 
       // A vector of all Archives. Used to avoid duplicating
       // an Archive that already exists.
-      static vector<Archive *> allArchives;
+      static std::vector<Archive *> allArchives;
 
       static SymtabError serr;
       static std::string errMsg;
diff --git a/symtabAPI/src/Archive-elf.C b/symtabAPI/src/Archive-elf.C
index 828a289..dcc3824 100644
--- a/symtabAPI/src/Archive-elf.C
+++ b/symtabAPI/src/Archive-elf.C
@@ -67,7 +67,7 @@ Archive::Archive(std::string& filename, bool& err)
 
     while( newelf->e_elfp() ) {
 	archdr = elf_getarhdr(newelf->e_elfp());
-	string member_name = archdr->ar_name;
+        std::string member_name = archdr->ar_name;
 
         if (elf_kind(newelf->e_elfp()) == ELF_K_ELF) {
             /* The offset is to the beginning of the arhdr for the member, not
@@ -116,7 +116,7 @@ bool Archive::parseMember(Symtab *&img, ArchiveMember *member)
     }
 
     // Sanity check
-    assert(member->getName() == string(arhdr->ar_name));
+    assert(member->getName() == std::string(arhdr->ar_name));
 
     size_t rawSize;
     char * rawMember = elf_rawfile(elfHdr, &rawSize);
@@ -156,13 +156,13 @@ bool Archive::parseSymbolTable() {
     size_t numSyms;
     if( (ar_syms = elf_getarsym(static_cast<Elf_X *>(basePtr)->e_elfp(), &numSyms)) == NULL ) {
         serr = Obj_Parsing;
-        errMsg = string("No symbol table found: ") + string(elf_errmsg(elf_errno()));
+        errMsg = "No symbol table found: " + std::string(elf_errmsg(elf_errno()));
         return false;
     }
 
     // The last element is always a null element
     for(unsigned i = 0; i < (numSyms - 1); i++) {
-        string symbol_name(ar_syms[i].as_name);
+        std::string symbol_name(ar_syms[i].as_name);
 
         // Duplicate symbols are okay here, they should be treated as errors
         // when necessary
diff --git a/symtabAPI/src/Archive.C b/symtabAPI/src/Archive.C
index 55cb3b9..8c9bb14 100644
--- a/symtabAPI/src/Archive.C
+++ b/symtabAPI/src/Archive.C
@@ -140,9 +140,9 @@ bool Archive::openArchive(Archive * &img, char *mem_image, size_t size)
     return err;
 }
 
-bool Archive::getMember(Symtab *&img, string& member_name) 
+bool Archive::getMember(Symtab *&img, std::string& member_name) 
 {
-    dyn_hash_map<string, ArchiveMember *>::iterator mem_it;
+    dyn_hash_map<std::string, ArchiveMember *>::iterator mem_it;
     mem_it = membersByName.find(member_name);
     if ( mem_it == membersByName.end() ) {
         serr = No_Such_Member;
@@ -180,7 +180,7 @@ bool Archive::getMemberByOffset(Symtab *&img, Offset memberOffset)
     return true;
 }
 
-bool Archive::getMemberByGlobalSymbol(Symtab *&img, string& symbol_name) 
+bool Archive::getMemberByGlobalSymbol(Symtab *&img, std::string& symbol_name) 
 {
     if( !symbolTableParsed ) {
        if( !parseSymbolTable() ) {
@@ -188,8 +188,8 @@ bool Archive::getMemberByGlobalSymbol(Symtab *&img, string& symbol_name)
        }
     }
 
-    std::pair<std::multimap<string, ArchiveMember *>::iterator,
-              std::multimap<string, ArchiveMember *>::iterator> range_it;
+    std::pair<std::multimap<std::string, ArchiveMember *>::iterator,
+              std::multimap<std::string, ArchiveMember *>::iterator> range_it;
     range_it = membersBySymbol.equal_range(symbol_name);
 
     // Symbol not found in symbol table
@@ -223,8 +223,8 @@ bool Archive::getMembersBySymbol(std::string name,
    if (!symbolTableParsed && !parseSymbolTable())
       return false;
    
-   std::pair<std::multimap<string, ArchiveMember *>::iterator,
-      std::multimap<string, ArchiveMember *>::iterator> range_it;
+   std::pair<std::multimap<std::string, ArchiveMember *>::iterator,
+      std::multimap<std::string, ArchiveMember *>::iterator> range_it;
    
    range_it = membersBySymbol.equal_range(name);
    auto begin = range_it.first;
@@ -240,9 +240,9 @@ bool Archive::getMembersBySymbol(std::string name,
    return true;
 }
 
-bool Archive::getAllMembers(vector<Symtab *> &members) 
+bool Archive::getAllMembers(std::vector<Symtab *> &members) 
 {
-    dyn_hash_map<string, ArchiveMember *>::iterator mem_it;
+    dyn_hash_map<std::string, ArchiveMember *>::iterator mem_it;
     for(mem_it = membersByName.begin(); mem_it != membersByName.end(); ++mem_it) {
         Symtab *img = mem_it->second->getSymtab();
         if( img == NULL) {
@@ -296,7 +296,7 @@ bool Archive::findMemberWithDefinition(Symtab * &obj, std::string& name)
 
 Archive::~Archive()
 {
-    dyn_hash_map<string, ArchiveMember *>::iterator it;
+    dyn_hash_map<std::string, ArchiveMember *>::iterator it;
     for (it = membersByName.begin(); it != membersByName.end(); ++it) {
         if (it->second) delete it->second;
     }
-- 
2.8.1

[← Prev in Thread] Current Thread [Next in Thread→]