From 900c562b71b6efcf68d649cb639cc8bc246d5899 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 6 Nov 2018 13:01:18 +1100 Subject: Cleanup: rename fast-heap -> heap-simple In general prefer API names don't start with adjectives since it causes grouping of unrelated API's for completion. --- source/blender/blenlib/BLI_heap_simple.h | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) (limited to 'source/blender/blenlib/BLI_heap_simple.h') diff --git a/source/blender/blenlib/BLI_heap_simple.h b/source/blender/blenlib/BLI_heap_simple.h index 077c8cc1bb9..eed33558d84 100644 --- a/source/blender/blenlib/BLI_heap_simple.h +++ b/source/blender/blenlib/BLI_heap_simple.h @@ -26,20 +26,19 @@ * \brief A min-heap / priority queue ADT */ - -struct FastHeap; -typedef struct FastHeap FastHeap; +struct HeapSimple; +typedef struct HeapSimple HeapSimple; typedef void (*HeapSimpleFreeFP)(void *ptr); -FastHeap *BLI_fastheap_new_ex(unsigned int tot_reserve) ATTR_WARN_UNUSED_RESULT; -FastHeap *BLI_fastheap_new(void) ATTR_WARN_UNUSED_RESULT; -void BLI_fastheap_clear(FastHeap *heap, HeapSimpleFreeFP ptrfreefp) ATTR_NONNULL(1); -void BLI_fastheap_free(FastHeap *heap, HeapSimpleFreeFP ptrfreefp) ATTR_NONNULL(1); -void BLI_fastheap_insert(FastHeap *heap, float value, void *ptr) ATTR_NONNULL(1); -bool BLI_fastheap_is_empty(const FastHeap *heap) ATTR_NONNULL(1); -uint BLI_fastheap_len(const FastHeap *heap) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1); -float BLI_fastheap_top_value(const FastHeap *heap) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1); -void *BLI_fastheap_pop_min(FastHeap *heap) ATTR_NONNULL(1); +HeapSimple *BLI_heapsimple_new_ex(unsigned int tot_reserve) ATTR_WARN_UNUSED_RESULT; +HeapSimple *BLI_heapsimple_new(void) ATTR_WARN_UNUSED_RESULT; +void BLI_heapsimple_clear(HeapSimple *heap, HeapSimpleFreeFP ptrfreefp) ATTR_NONNULL(1); +void BLI_heapsimple_free(HeapSimple *heap, HeapSimpleFreeFP ptrfreefp) ATTR_NONNULL(1); +void BLI_heapsimple_insert(HeapSimple *heap, float value, void *ptr) ATTR_NONNULL(1); +bool BLI_heapsimple_is_empty(const HeapSimple *heap) ATTR_NONNULL(1); +uint BLI_heapsimple_len(const HeapSimple *heap) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1); +float BLI_heapsimple_top_value(const HeapSimple *heap) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1); +void *BLI_heapsimple_pop_min(HeapSimple *heap) ATTR_NONNULL(1); #endif /* __BLI_HEAP_SIMPLE_H__ */ -- cgit v1.2.3