blob: 48a1fba5d04528864c6c8c971eb146d88d4ade31 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
$NetBSD: patch-ao,v 1.1.1.1 2005/02/28 12:37:30 spz Exp $
--- src/util/Stack.hh.orig 2005-02-26 11:50:00.000000000 +0100
+++ src/util/Stack.hh
@@ -100,9 +100,9 @@ class BoundedStack : BoundedQueue<TYPE>
public:
BoundedStack(int size) : BoundedQueue<TYPE>(size) {}
void push(TYPE elt) { enq(elt); }
- TYPE pop() { return q[--last]; }
- int getPosition() { return last; }
- void setPosition(int pos) { last = pos; }
+ TYPE pop() { return BoundedQueue<TYPE>::q[--BoundedQueue<TYPE>::last]; }
+ int getPosition() { return BoundedQueue<TYPE>::last; }
+ void setPosition(int pos) { BoundedQueue<TYPE>::last = pos; }
void clear() {
BoundedQueue<TYPE>::clear();
}
|