1
0
mirror of https://git.savannah.gnu.org/git/gperf.git synced 2025-12-02 21:19:24 +00:00

Improve debugging output.

This commit is contained in:
Bruno Haible
2003-03-04 06:05:14 +00:00
parent 9fa3ac42b3
commit 9492f0dad7
6 changed files with 149 additions and 30 deletions

View File

@@ -137,3 +137,20 @@ PositionIterator::next ()
{
return (_index < _set._size ? _set._positions[_index++] : EOS);
}
/* --------------------- Class PositionReverseIterator --------------------- */
/* Initializes an iterator through POSITIONS. */
INLINE
PositionReverseIterator::PositionReverseIterator (Positions const& positions)
: _set (positions),
_index (_set._size)
{
}
/* Retrieves the next position, or EOS past the end. */
INLINE int
PositionReverseIterator::next ()
{
return (_index > 0 ? _set._positions[--_index] : EOS);
}