summaryrefslogtreecommitdiff
path: root/src/pathfinder/npf/queue.h
diff options
context:
space:
mode:
authoralberth <alberth@openttd.org>2010-08-29 13:38:43 +0000
committeralberth <alberth@openttd.org>2010-08-29 13:38:43 +0000
commit2c962548e52e6334db0c2457eedb40710b23bbad (patch)
tree058b6c877e8b1c388a9140470b975d463feae994 /src/pathfinder/npf/queue.h
parentb06cedc905fbc1c8917f45cadfd78b246e4924f0 (diff)
downloadopenttd-2c962548e52e6334db0c2457eedb40710b23bbad.tar.xz
(svn r20685) -Codechange: Make BinaryHeap_Clear() a method.
Diffstat (limited to 'src/pathfinder/npf/queue.h')
-rw-r--r--src/pathfinder/npf/queue.h10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/pathfinder/npf/queue.h b/src/pathfinder/npf/queue.h
index 1d6831157..317ec1b71 100644
--- a/src/pathfinder/npf/queue.h
+++ b/src/pathfinder/npf/queue.h
@@ -18,9 +18,6 @@
//#define HASH_STATS
-struct Queue;
-typedef void Queue_ClearProc(Queue *q, bool free_values);
-
struct BinaryHeapNode {
void *item;
int priority;
@@ -31,12 +28,7 @@ struct Queue {
bool Push(void *item, int priority);
void *Pop();
bool Delete(void *item, int priority);
-
- /* Clears the queue, by removing all values from it. Its state is
- * effectively reset. If free_items is true, each of the items cleared
- * in this way are free()'d.
- */
- Queue_ClearProc *clear;
+ void Clear(bool free_values);
void Free(bool free_values);
uint max_size;