[llvm-commits] CVS: llvm/include/Support/ilist

Chris Lattner lattner at cs.uiuc.edu
Fri Aug 29 09:23:02 PDT 2003


Changes in directory llvm/include/Support:

ilist updated: 1.9 -> 1.10

---
Log message:

Fix compilation problems with G++ 3.4


---
Diffs of the changes:

Index: llvm/include/Support/ilist
diff -u llvm/include/Support/ilist:1.9 llvm/include/Support/ilist:1.10
--- llvm/include/Support/ilist:1.9	Fri Jul 25 12:23:13 2003
+++ llvm/include/Support/ilist	Fri Aug 29 09:22:29 2003
@@ -198,7 +198,7 @@
   typedef std::reverse_iterator<const_iterator>  const_reverse_iterator;
   typedef std::reverse_iterator<iterator>  reverse_iterator;
 
-  iplist() : Head(createNode()), Tail(Head) {
+  iplist() : Head(this->createNode()), Tail(Head) {
     setNext(Head, 0);
     setPrev(Head, 0);
   }
@@ -441,16 +441,16 @@
 
   ilist() {}
   ilist(const ilist &right) {
-    insert(begin(), right.begin(), right.end());
+    insert(this->begin(), right.begin(), right.end());
   }
   explicit ilist(size_type count) {
-    insert(begin(), count, NodeTy());
+    insert(this->begin(), count, NodeTy());
   } 
   ilist(size_type count, const NodeTy &val) {
-    insert(begin(), count, val);
+    insert(this->begin(), count, val);
   }
   template<class InIt> ilist(InIt first, InIt last) {
-    insert(begin(), first, last);
+    insert(this->begin(), first, last);
   }
 
 
@@ -469,8 +469,8 @@
 
 
   // Front and back inserters...
-  void push_front(const NodeTy &val) { insert(begin(), val); }
-  void push_back(const NodeTy &val) { insert(end(), val); }
+  void push_front(const NodeTy &val) { insert(this->begin(), val); }
+  void push_back(const NodeTy &val) { insert(this->end(), val); }
 
   // Special forms of insert...
   template<class InIt> void insert(iterator where, InIt first, InIt last) {
@@ -482,16 +482,16 @@
 
   // Assign special forms...
   void assign(size_type count, const NodeTy &val) {
-    iterator I = begin();
-    for (; I != end() && count != 0; ++I, --count)
+    iterator I = this->begin();
+    for (; I != this->end() && count != 0; ++I, --count)
       *I = val;
     if (count != 0)
-      insert(end(), n, val);
+      insert(this->end(), val, val);
     else
-      erase(I, end());
+      erase(I, this->end());
   }
-  template<class InIt> void assign(InIt first, InIt last) {
-    iterator first1 = begin(), last1 = end();
+  template<class InIt> void assign(InIt first1, InIt last1) {
+    iterator first2 = this->begin(), last2 = this->end();
     for ( ; first1 != last1 && first2 != last2; ++first1, ++first2)
       *first1 = *first2;
     if (first2 == last2)
@@ -503,14 +503,14 @@
 
   // Resize members...
   void resize(size_type newsize, NodeTy val) {
-    iterator i = begin();
+    iterator i = this->begin();
     size_type len = 0;
-    for ( ; i != end() && len < newsize; ++i, ++len) /* empty*/ ;
+    for ( ; i != this->end() && len < newsize; ++i, ++len) /* empty*/ ;
 
     if (len == newsize)
-      erase(i, end());
+      erase(i, this->end());
     else                                          // i == end()
-      insert(end(), newsize - len, val);
+      insert(this->end(), newsize - len, val);
   }
   void resize(size_type newsize) { resize(newsize, NodeTy()); }
 };





More information about the llvm-commits mailing list