aboutsummaryrefslogtreecommitdiff
path: root/include/llvm/Analysis/DataStructure
diff options
context:
space:
mode:
authorBrian Gaeke <gaeke@uiuc.edu>2003-11-11 22:41:34 +0000
committerBrian Gaeke <gaeke@uiuc.edu>2003-11-11 22:41:34 +0000
commitd0fde30ce850b78371fd1386338350591f9ff494 (patch)
tree83bb73e83f54fc8e1e474d116250ae2779562f7e /include/llvm/Analysis/DataStructure
parent0d723acf15b0326e2df09ecb614b02a617f536e4 (diff)
Put all LLVM code into the llvm namespace, as per bug 109.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9903 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Analysis/DataStructure')
-rw-r--r--include/llvm/Analysis/DataStructure/DSGraph.h5
-rw-r--r--include/llvm/Analysis/DataStructure/DSGraphTraits.h4
-rw-r--r--include/llvm/Analysis/DataStructure/DSNode.h4
-rw-r--r--include/llvm/Analysis/DataStructure/DSSupport.h12
-rw-r--r--include/llvm/Analysis/DataStructure/DataStructure.h4
5 files changed, 27 insertions, 2 deletions
diff --git a/include/llvm/Analysis/DataStructure/DSGraph.h b/include/llvm/Analysis/DataStructure/DSGraph.h
index 399da007e2..b7fdb10af5 100644
--- a/include/llvm/Analysis/DataStructure/DSGraph.h
+++ b/include/llvm/Analysis/DataStructure/DSGraph.h
@@ -15,6 +15,9 @@
#define LLVM_ANALYSIS_DSGRAPH_H
#include "llvm/Analysis/DSNode.h"
+
+namespace llvm {
+
class GlobalValue;
//===----------------------------------------------------------------------===//
@@ -332,4 +335,6 @@ public:
void removeTriviallyDeadNodes();
};
+} // End llvm namespace
+
#endif
diff --git a/include/llvm/Analysis/DataStructure/DSGraphTraits.h b/include/llvm/Analysis/DataStructure/DSGraphTraits.h
index 086835cb92..ad2cc6fa8f 100644
--- a/include/llvm/Analysis/DataStructure/DSGraphTraits.h
+++ b/include/llvm/Analysis/DataStructure/DSGraphTraits.h
@@ -21,6 +21,8 @@
#include "Support/iterator"
#include "Support/STLExtras.h"
+namespace llvm {
+
template<typename NodeTy>
class DSNodeIterator : public forward_iterator<const DSNode, ptrdiff_t> {
friend class DSNode;
@@ -146,4 +148,6 @@ template <> struct GraphTraits<const DSGraph*> {
static ChildIteratorType child_end(const NodeType *N) { return N->end(); }
};
+} // End llvm namespace
+
#endif
diff --git a/include/llvm/Analysis/DataStructure/DSNode.h b/include/llvm/Analysis/DataStructure/DSNode.h
index ba5328b2b8..f206c3e5ad 100644
--- a/include/llvm/Analysis/DataStructure/DSNode.h
+++ b/include/llvm/Analysis/DataStructure/DSNode.h
@@ -16,6 +16,8 @@
#include "llvm/Analysis/DSSupport.h"
+namespace llvm {
+
template<typename BaseType>
class DSNodeIterator; // Data structure graph traversal iterator
class TargetData;
@@ -382,4 +384,6 @@ inline void DSNodeHandle::mergeWith(const DSNodeHandle &Node) {
*this = Node;
}
+} // End llvm namespace
+
#endif
diff --git a/include/llvm/Analysis/DataStructure/DSSupport.h b/include/llvm/Analysis/DataStructure/DSSupport.h
index e5662ff0a4..4b571917ff 100644
--- a/include/llvm/Analysis/DataStructure/DSSupport.h
+++ b/include/llvm/Analysis/DataStructure/DSSupport.h
@@ -18,6 +18,8 @@
#include "Support/hash_set"
#include "llvm/Support/CallSite.h"
+namespace llvm {
+
class Function;
class CallInst;
class Value;
@@ -122,10 +124,14 @@ private:
DSNode *HandleForwarding() const;
};
+} // End llvm namespace
+
namespace std {
- inline void swap(DSNodeHandle &NH1, DSNodeHandle &NH2) { NH1.swap(NH2); }
+ inline void swap(llvm::DSNodeHandle &NH1, llvm::DSNodeHandle &NH2) { NH1.swap(NH2); }
}
+namespace llvm {
+
//===----------------------------------------------------------------------===//
/// DSCallSite - Representation of a call site via its call instruction,
/// the DSNode handle for the callee function (or function pointer), and
@@ -287,7 +293,9 @@ public:
}
};
+} // End llvm namespace
+
namespace std {
- inline void swap(DSCallSite &CS1, DSCallSite &CS2) { CS1.swap(CS2); }
+ inline void swap(llvm::DSCallSite &CS1, llvm::DSCallSite &CS2) { CS1.swap(CS2); }
}
#endif
diff --git a/include/llvm/Analysis/DataStructure/DataStructure.h b/include/llvm/Analysis/DataStructure/DataStructure.h
index afea126c07..4d6e3a0476 100644
--- a/include/llvm/Analysis/DataStructure/DataStructure.h
+++ b/include/llvm/Analysis/DataStructure/DataStructure.h
@@ -18,6 +18,8 @@
#include "llvm/Target/TargetData.h"
#include "Support/hash_set"
+namespace llvm {
+
class Type;
class Instruction;
class DSGraph;
@@ -184,4 +186,6 @@ private:
const BUDataStructures::ActualCalleesTy &ActualCallees);
};
+} // End llvm namespace
+
#endif