Add a value_type typedef to SmallVector, to make it more compatible with STL adapters.
[oota-llvm.git] / include / llvm / GlobalAlias.h
index 7c147eb62a39f0aa90d5b96cb60985286154e9e9..124cf94fa9a4ee1c05742faeb3046041204f2b2a 100644 (file)
@@ -17,6 +17,7 @@
 
 #include "llvm/GlobalValue.h"
 #include "llvm/OperandTraits.h"
+#include "llvm/ADT/ilist_node.h"
 
 namespace llvm {
 
@@ -26,23 +27,13 @@ class PointerType;
 template<typename ValueSubClass, typename ItemParentClass>
   class SymbolTableListTraits;
 
-class GlobalAlias : public GlobalValue {
+class GlobalAlias : public GlobalValue, public ilist_node<GlobalAlias> {
   friend class SymbolTableListTraits<GlobalAlias, Module>;
   void operator=(const GlobalAlias &);     // Do not implement
   GlobalAlias(const GlobalAlias &);     // Do not implement
 
   void setParent(Module *parent);
 
-  GlobalAlias *Prev, *Next;
-  void setNext(GlobalAlias *N) { Next = N; }
-  void setPrev(GlobalAlias *N) { Prev = N; }
-
-  // getNext/Prev - Return the next or previous alias in the list.
-        GlobalAlias *getNext()       { return Next; }
-  const GlobalAlias *getNext() const { return Next; }
-        GlobalAlias *getPrev()       { return Prev; }
-  const GlobalAlias *getPrev() const { return Prev; }
-
 public:
   // allocate space for exactly one operand
   void *operator new(size_t s) {