diff options
Diffstat (limited to 'Carpet/CarpetLib')
-rw-r--r-- | Carpet/CarpetLib/src/fulltree.cc | 2 | ||||
-rw-r--r-- | Carpet/CarpetLib/src/fulltree.hh | 9 |
2 files changed, 9 insertions, 2 deletions
diff --git a/Carpet/CarpetLib/src/fulltree.cc b/Carpet/CarpetLib/src/fulltree.cc index 2687a5b61..0318cb83c 100644 --- a/Carpet/CarpetLib/src/fulltree.cc +++ b/Carpet/CarpetLib/src/fulltree.cc @@ -315,7 +315,7 @@ fulltree<T,D,P>::iterator::~iterator () template <typename T, int D, typename P> fulltree<T,D,P> & -fulltree<T,D,P>::iterator::operator* () +fulltree<T,D,P>::iterator::operator* () const { assert (not done()); assert (not f.empty()); diff --git a/Carpet/CarpetLib/src/fulltree.hh b/Carpet/CarpetLib/src/fulltree.hh index e0c55fbfa..d8869a919 100644 --- a/Carpet/CarpetLib/src/fulltree.hh +++ b/Carpet/CarpetLib/src/fulltree.hh @@ -127,7 +127,7 @@ public: iterator (fulltree & f_); iterator (fulltree & f_, int); ~iterator (); - fulltree & operator* (); + fulltree & operator* () const; bool operator== (iterator const & it2) const; bool operator!= (iterator const & it2) const { return not (*this == it2); } @@ -135,6 +135,12 @@ public: bool done () const; }; +#if 0 + // ES 2008-09-04: + // It seems that PGI does not handle comparisons to end() correctly. + // We therefore disable these; please use the iterators' + // constructors and their done() methods instead. + const_iterator begin() const { return const_iterator (*this); } @@ -146,6 +152,7 @@ public: iterator end() { return iterator (*this, 0); } +#endif // Memory usage size_t memory () const; |