aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/llvm/CFGdecls.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/llvm/CFGdecls.h b/include/llvm/CFGdecls.h
index 8d4152fea0..b59a1d2536 100644
--- a/include/llvm/CFGdecls.h
+++ b/include/llvm/CFGdecls.h
@@ -73,6 +73,7 @@ struct BasicBlockGraph;
struct ConstBasicBlockGraph;
struct InverseBasicBlockGraph;
struct ConstInverseBasicBlockGraph;
+struct TypeGraph;
// Forward declare iterator class template...
template<class GraphInfo> class DFIterator;
@@ -104,6 +105,15 @@ inline idf_iterator idf_end ( BasicBlock *BB);
inline idf_const_iterator idf_end (const BasicBlock *BB);
+// Depth First Iterator Definitions for Types. This lets you iterator over
+// (possibly cyclic) type graphs in dfo
+//
+typedef DFIterator<TypeGraph> tdf_iterator;
+
+inline tdf_iterator tdf_begin(const Type *T, bool Reverse = false);
+inline tdf_iterator tdf_end (const Type *T);
+
+
//===--------------------------------------------------------------------===//
// Post Order CFG iterator code
//===--------------------------------------------------------------------===//