From ccdacf1c9b31b15e188aa9e9adb044ffd0ca0da4 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Thu, 15 Feb 2018 23:36:11 +1100 Subject: Cleanup: use '_len' instead of '_size' w/ BLI API - When returning the number of items in a collection use BLI_*_len() - Keep _size() for size in bytes. - Keep _count() for data structures that don't store length (hint this isn't a simple getter). See P611 to apply instead of manually resolving conflicts. --- source/blender/blenlib/intern/gsqueue.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/blender/blenlib/intern/gsqueue.c') diff --git a/source/blender/blenlib/intern/gsqueue.c b/source/blender/blenlib/intern/gsqueue.c index 25da7701924..5c8c43ab92a 100644 --- a/source/blender/blenlib/intern/gsqueue.c +++ b/source/blender/blenlib/intern/gsqueue.c @@ -81,7 +81,7 @@ bool BLI_gsqueue_is_empty(GSQueue *gq) /** * Query number elements in the queue */ -int BLI_gsqueue_size(GSQueue *gq) +int BLI_gsqueue_len(GSQueue *gq) { GSQueueElem *elem; int size = 0; @@ -162,7 +162,7 @@ void BLI_gsqueue_push(GSQueue *gq, const void *item) * \param item A pointer to an appropriately * sized structure (the size passed to BLI_gsqueue_new). */ -void BLI_gsqueue_pushback(GSQueue *gq, const void *item) +void BLI_gsqueue_push_back(GSQueue *gq, const void *item) { GSQueueElem *elem = MEM_mallocN(sizeof(*elem) + gq->elem_size, "gqueue_push"); memcpy(elem->data, item, gq->elem_size); -- cgit v1.2.3