aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/eina/eina_array.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/eina/eina_array.h')
-rw-r--r--src/lib/eina/eina_array.h491
1 files changed, 201 insertions, 290 deletions
diff --git a/src/lib/eina/eina_array.h b/src/lib/eina/eina_array.h
index 07234cd70b..da046d786f 100644
--- a/src/lib/eina/eina_array.h
+++ b/src/lib/eina/eina_array.h
@@ -1,7 +1,7 @@
/* EINA - EFL data type library
* Copyright (C) 2008 Cedric Bail
*
- * This library is free software; you can redistribute it and/or
+ * This library is a free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
@@ -29,139 +29,31 @@
#include "eina_accessor.h"
#include "eina_magic.h"
-
-/**
- * @page eina_array_01_example_page Basic array usage
- * @dontinclude eina_array_01.c
- *
- * For this example we add stdlib.h, stdio.h and string.h for some
- * convenience functions. The first thing to do to be able to use an
- * @ref Eina_Array is to include Eina.h:
- * @skip #include
- * @until Eina.h
- *
- * Here we have a callback that prints the element given to it:
- * @until }
- *
- * Now we create our entry point and declare some variables, nothing especial:
- * @until unsigned
- *
- * Before we can start using any array function we need to initialize eina:
- * @until eina_init
- *
- * So now to actually create our array. The only interesting thing here is the
- * argument given to the eina_array_new() function. This argument sets how fast
- * the array grows.
- * @until array_new
- *
- * If you know before hand how big the array will need to be you should set the
- * step to that. In our case we can set it to the number of strings we have and
- * since we didn't do that in the eina_array_new() we can do it now:
- * @until array_step_set
- *
- * Now let us populate our array with some strings:
- * @until push
- * @note Notice we use strdup, so we will have to free that memory later on.
- *
- * Now lets check the size of the array:
- * @until printf
- *
- * And now we call a function on every member of our array to print it:
- * @until foreach
- *
- * One of the strengths of @ref Eina_Array over @ref Eina_List is that it has
- * very fast random access to elements, so this is very efficient:
- * @until printf
- *
- * And now we free up the memory allocated with the strdup()s:
- * @until free
- *
- * And the array memory itself:
- * @until array_free
- *
- * And finally shutdown eina and exit:
- * @until }
- *
- * The full source code can be found in the examples folder
- * in the @ref eina_array_01_c "eina_array_01.c" file.
- */
-
-/**
- * @page eina_array_01_c Basic array usage example
- *
- * @include eina_array_01.c
- * @example eina_array_01.c
- */
-
-/**
- * @page eina_array_02_example_page Removing array elements
- * @dontinclude eina_array_02.c
- *
- * Just the usual includes:
- * @skip #include
- * @until Eina.h
- *
- * This the callback we are going to use to decide which strings stay on the
- * array and which will be removed. We use something simple, but this can be as
- * complex as you like:
- * @until }
- *
- * This is the same code we used before to populate the list with the slight
- * difference of not using strdup:
- * @until array_push
- *
- * So we have added all our elements to the array, but it turns out that is not
- * the elements we wanted, so let's empty the array and add the correct strings:
- * @until array_push
- *
- * It seems we made a little mistake in one of our strings so we need to replace
- * it, here is how:
- * @until data_set
- *
- * Now that there is a populated array we can remove elements from it easily:
- * @until array_remove
- *
- * And check that the elements were actually removed:
- * @until printf
- *
- * Since this time we didn't use strdup we don't need to free each string:
- * @until }
- *
- * The full source code can be found in the examples folder
- * in the @ref eina_array_02_c "eina_array_02.c" file.
- */
-
/**
- * @page eina_array_02_c Basic array usage example
- *
- * @include eina_array_02.c
- * @example eina_array_02.c
- */
-
-/**
- * @addtogroup Eina_Array_Group Array
+ * @defgroup Eina_Array_Group Array
+ * @ingroup Eina_Containers_Group
*
- * @brief These functions provide array management.
+ * @brief This group discusses the functions to provide array management.
*
* The Array data type in Eina is designed to have very fast access to
* its data (compared to the Eina @ref Eina_List_Group). On the other hand,
* data can be added or removed only at the end of the array. To insert
- * data at any position, the Eina @ref Eina_List_Group is the correct container
+ * data at any place, the Eina @ref Eina_List_Group is the correct container
* to use.
*
* To use the array data type, eina_init() must be called before any
- * other array functions. When no more eina array functions are used,
+ * other array function. When no more eina array functions are used,
* eina_shutdown() must be called to free all the resources.
*
* An array must be created with eina_array_new(). It allocates all
* the necessary data for an array. When not needed anymore, an array
- * is freed with eina_array_free(). This frees the memory used by the Eina_Array
- * itself, but does not free any memory used to store the data of each element.
- * To free that memory you must iterate over the array and free each data element
- * individually. A convenient way to do that is by using #EINA_ARRAY_ITER_NEXT.
- * An example of that pattern is given in the description of @ref EINA_ARRAY_ITER_NEXT.
+ * is freed with eina_array_free(). This function does not free any
+ * allocated memory used to store the data of each element. For that,
+ * just iterate over the array to free them. A convenient way to do
+ * that is by using #EINA_ARRAY_ITER_NEXT. An example of code is given
+ * in the description of this macro.
*
- * @warning Functions do not check if the used array is valid or not. It's up to
+ * Functions do not check if the used array is valid or not. It's up to
* the user to be sure of that. It is designed like that for performance
* reasons.
*
@@ -173,157 +65,157 @@
*
* Eina_Array is different from a conventional C array in a number of ways, most
* importantly they grow and shrink dynamically, this means that if you add an
- * element to a full array it grows and that when you remove an element from an
+ * element to a full array it grows and when you remove an element from an
* array it @b may shrink.
*
- * Allocating memory is expensive, so when the array needs to grow it allocates
- * enough memory to hold @p step additonal elements, not just the element
- * currently being added. Similarly if you remove elements, it won't free space
- * until you have removed @p step elements.
+ * When the array needs to grow it allocates memory not just for the element
+ * currently being added, since that would mean allocating memory(which is
+ * computationally expensive) often, instead it grows to be able to hold @a step
+ * more elements. Similarly, if you remove elements in such a way that the
+ * array is left holding its capacity, @a step elements shrink.
*
* The following image illustrates how an Eina_Array grows:
*
* @image html eina_array-growth.png
- * @image latex eina_array-growth.eps "" width=\textwidth
- *
- * Eina_Array only stores pointers but it can store data of any type in the form
- * of void pointers.
+ * @image latex eina_array-growth.eps "eina array growth" width=\textwidth
*
- * See here some examples:
- * @li @ref eina_array_01_example_page
- * @li @ref eina_array_02_example_page
- */
-
-/**
- * @addtogroup Eina_Data_Types_Group Data Types
- *
- * @{
- */
-
-/**
- * @addtogroup Eina_Containers_Group Containers
- *
- * @{
- */
-
-/**
- * @defgroup Eina_Array_Group Array
+ * @remarks Eina_Array only stores pointers, but it can store data of any type in the form
+ * of void pointers.
*
* @{
*/
/**
* @typedef Eina_Array
- * Type for a generic vector.
+ * @brief The structure type for a generic vector.
*/
typedef struct _Eina_Array Eina_Array;
/**
* @typedef Eina_Array_Iterator
- * Type for an iterator on arrays, used with #EINA_ARRAY_ITER_NEXT.
+ * @brief The structure type for an iterator on arrays, used with #EINA_ARRAY_ITER_NEXT.
*/
typedef void **Eina_Array_Iterator;
/**
* @struct _Eina_Array
- * Type for an array of data.
+ * @brief The structure type for an array of data.
*/
struct _Eina_Array
{
#define EINA_ARRAY_VERSION 1
- int version; /**< Should match EINA_ARRAY_VERSION used when compiled your apps, provided for ABI compatibility */
+ int version; /**< Should match EINA_ARRAY_VERSION used when compiling your apps, provided for ABI compatibility */
- void **data; /**< Pointer to a vector of pointer to payload */
- unsigned int total; /**< Number of allocated slots in the vector */
- unsigned int count; /**< Number of slots in the vector that actually point to data */
- unsigned int step; /**< Number of slots to grow or shrink the vector */
+ void **data; /**< Pointer to a vector of a pointer to payload */
+ unsigned int total; /**< Total number of slots in the vector */
+ unsigned int count; /**< Number of active slots in the vector */
+ unsigned int step; /**< To what extent must we grow the vector when it is full */
EINA_MAGIC
};
/**
- * @brief Create a new array.
+ * @brief Creates a new array.
*
- * @param step The count of pointers to add when increasing the array size.
- * @return @c NULL on failure, non @c NULL otherwise.
+ * @details This function creates a new array. When adding an element, the array
+ * allocates @a step elements. When that buffer is full, adding
+ * another element increases the buffer by @a step elements again.
*
- * This function creates a new array. When adding an element, the array
- * allocates @p step elements. When that buffer is full, then adding
- * another element will increase the buffer by @p step elements again.
+ * @since_tizen 2.3
+ *
+ * @remarks This function returns a valid array on success, or @c NULL if memory
+ * allocation fails. In that case, the error is set
+ * to #EINA_ERROR_OUT_OF_MEMORY.
+ *
+ * @param[in] step The count of pointers to add when increasing the array size
+ * @return @c NULL on failure, otherwise a non @c NULL value
*
- * This function return a valid array on success, or @c NULL if memory
- * allocation fails.
*/
EAPI Eina_Array *eina_array_new(unsigned int step) EINA_WARN_UNUSED_RESULT EINA_MALLOC EINA_WARN_UNUSED_RESULT;
/**
- * @brief Free an array.
+ * @brief Frees an array.
+ *
+ * @details This function frees @a array. It calls first eina_array_flush() then
+ * frees the memory of the pointer. It does not free the memory
+ * allocated for the elements of @a array. To free them,
+ * use #EINA_ARRAY_ITER_NEXT. For performance reasons, there is no check
+ * on @a array.
+ *
+ * @since_tizen 2.3
*
- * @param array The array to free.
+ * @param[in] array The array to free
*
- * This function frees @p array. It calls first eina_array_flush() then
- * free the memory of the pointer. It does not free the memory
- * allocated for the elements of @p array. To free them, walk the array with
- * #EINA_ARRAY_ITER_NEXT. For performance reasons, there is no check
- * of @p array.
*/
EAPI void eina_array_free(Eina_Array *array) EINA_ARG_NONNULL(1);
/**
- * @brief Set the step of an array.
+ * @brief Sets the step of an array.
*
- * @param array The array.
- * @param sizeof_eina_array Should be the value returned by sizeof(Eina_Array).
- * @param step The count of pointers to add when increasing the array size.
+ * @details This function sets the step of @a array to @a step. For performance
+ * reasons, there is no check on @a array. If it is @c NULL or
+ * invalid, the program may crash.
*
- * This function sets the step of @p array to @p step. For performance
- * reasons, there is no check of @p array. If it is @c NULL or
- * invalid, the program may crash.
+ * @since_tizen 2.3
+ *
+ * @remarks This function can @b only be called on uninitialized arrays.
+ *
+ * @param[in] array The array
+ * @param[in] sizeof_eina_array The value returned by sizeof(Eina_Array)
+ * @param[in] step The count of pointers to add when increasing the array size
*
- * @warning This function can @b only be called on uninitialized arrays.
*/
EAPI void eina_array_step_set(Eina_Array *array,
unsigned int sizeof_eina_array,
unsigned int step) EINA_ARG_NONNULL(1);
/**
- * @brief Clean an array.
+ * @brief Cleans an array.
+ *
+ * @details This function sets the count member of @a array to 0. However, it doesn't free
+ * any space. This is particularly useful if you need to empty the array and
+ * add lots of elements quickly. For performance reasons, there is no check on
+ * @a array. If it is @c NULL or invalid, the program may crash.
*
- * @param array The array to clean.
+ * @since_tizen 2.3
+ *
+ * @param[in] array The array to clean
*
- * This function sets the count member of @p array to 0, however it doesn't free
- * any space. This is particularly useful if you need to empty the array and
- * add lots of elements quickly. For performance reasons, there is no check of
- * @p array. If it is @c NULL or invalid, the program may crash.
*/
static inline void eina_array_clean(Eina_Array *array) EINA_ARG_NONNULL(1);
/**
- * @brief Flush an array.
+ * @brief Flushes an array.
+ *
+ * @details This function sets the count and total members of @a array to 0,
+ * frees and sets its data member to @c NULL. For performance reasons,
+ * there is no check on @a array. If it is @c NULL or invalid, the
+ * program may crash.
*
- * @param array The array to flush.
+ * @since_tizen 2.3
+ *
+ * @param[in] array The array to flush
*
- * This function sets the count and total members of @p array to 0,
- * frees and set to NULL its data member. For performance reasons,
- * there is no check of @p array. If it is @c NULL or invalid, the
- * program may crash.
*/
EAPI void eina_array_flush(Eina_Array *array) EINA_ARG_NONNULL(1);
/**
- * @brief Rebuild an array by specifying the data to keep.
+ * @brief Rebuilds an array by specifying the data to keep.
*
- * @param array The array.
- * @param keep The functions which selects the data to keep.
- * @param gdata The data to pass to the function keep.
- * @return #EINA_TRUE on success, #EINA_FALSE otherwise.
+ * @details This function rebuilds @a array by specifying the elements to keep with the
+ * function @a keep. No empty/invalid fields are left in the array. @a gdata is
+ * an additional data to pass to @a keep. For performance reasons, there is no
+ * check on @a array. If it is @c NULL or invalid, the program may crash.
*
- * This function rebuilds @p array be specifying the elements to keep with the
- * function @p keep. No empty/invalid fields are left in the array. @p gdata is
- * an additional data to pass to @p keep. For performance reasons, there is no
- * check of @p array. If it is @c NULL or invalid, the program may crash.
+ * @since_tizen 2.3
+ *
+ * @remarks If it isn't able to remove items due to an allocation failure, it
+ * returns @c EINA_FALSE and the error is set to #EINA_ERROR_OUT_OF_MEMORY.
+ *
+ * @param[in] array The array
+ * @param[in] keep The functions that selects the data to keep
+ * @param[in] gdata The data to pass to the function @a keep
+ * @return @c EINA_TRUE on success, otherwise @c EINA_FALSE
*
- * If it wasn't able to remove items due to an allocation failure, it will
- * return #EINA_FALSE.
*/
EAPI Eina_Bool eina_array_remove(Eina_Array * array,
Eina_Bool (*keep)(void *data, void *gdata),
@@ -332,15 +224,17 @@ EAPI Eina_Bool eina_array_remove(Eina_Array * array,
/**
* @brief Append a data to an array.
*
- * @param array The array.
- * @param data The data to add.
- * @return #EINA_TRUE on success, #EINA_FALSE otherwise.
+ * @details This function appends @p data to @p array. For performance
+ * reasons, there is no check of @p array. If it is @c NULL or
+ * invalid, the program may crash. If @p data is @c NULL, or if an
+ * allocation is necessary and fails, #EINA_FALSE is returned
+ * Otherwise, #EINA_TRUE is returned.
*
- * This function appends @p data to @p array. For performance
- * reasons, there is no check of @p array. If it is @c NULL or
- * invalid, the program may crash. If @p data is @c NULL, or if an
- * allocation is necessary and fails, #EINA_FALSE is returned
- * Otherwise, #EINA_TRUE is returned.
+ * @since_tizen 2.3
+ *
+ * @param[in] array The array.
+ * @param[in] data The data to add.
+ * @return #EINA_TRUE on success, #EINA_FALSE otherwise.
*/
static inline Eina_Bool eina_array_push(Eina_Array *array,
const void *data) EINA_ARG_NONNULL(1, 2);
@@ -348,55 +242,66 @@ static inline Eina_Bool eina_array_push(Eina_Array *array,
/**
* @brief Remove the last data of an array.
*
- * @param array The array.
- * @return The retrieved data.
+ * @details This function removes the last data of @p array, decreases the count
+ * of @p array and returns the data. For performance reasons, there
+ * is no check of @p array. If it is @c NULL or invalid, the program
+ * may crash. If the count member is less or equal than 0, @c NULL is
+ * returned.
+ *
+ * @since_tizen 2.3
*
- * This function removes the last data of @p array, decreases the count
- * of @p array and returns the data. For performance reasons, there
- * is no check of @p array. If it is @c NULL or invalid, the program
- * may crash. If the count member is less or equal than 0, @c NULL is
- * returned.
+ * @param[in] array The array.
+ * @return The retrieved data.
*/
static inline void *eina_array_pop(Eina_Array *array) EINA_ARG_NONNULL(1);
/**
- * @brief Return the data at a given position in an array.
+ * @brief Sets the data at the given position in an array.
*
- * @param array The array.
- * @param idx The potition of the data to retrieve.
- * @return The retrieved data.
+ * @details This function sets the data at the position @a idx in @a
+ * array to @a data, this effectively replaces the previously held data, you
+ * must therefore get a pointer to it first if you need to free it. For
+ * performance reasons, there is no check on @a array or @a idx. If it is
+ * @c NULL or invalid, the program may crash.
+ *
+ * @since_tizen 2.3
*
- * This function returns the data at the position @p idx in @p
- * array. For performance reasons, there is no check of @p array or @p
- * idx. If it is @c NULL or invalid, the program may crash.
+ * @param[in] array The array
+ * @param[in] idx The position of the data to set
*/
static inline void *eina_array_data_get(const Eina_Array *array,
unsigned int idx) EINA_ARG_NONNULL(1);
/**
- * @brief Set the data at a given position in an array.
- *
- * @param array The array.
- * @param idx The position of the data to set.
- * @param data The data to set.
- *
- * This function sets the data at the position @p idx in @p
- * array to @p data, this effectively replaces the previously held data, you
- * must therefore get a pointer to it first if you need to free it. For
- * performance reasons, there is no check of @p array or @p idx. If it is @c
- * NULL or invalid, the program may crash.
-*/
+ * @brief Sets the data at the given position in an array.
+ *
+ * @details This function sets the data at the position @a idx in @a
+ * array to @a data, this effectively replaces the previously held data, you
+ * must therefore get a pointer to it first if you need to free it. For
+ * performance reasons, there is no check on @a array or @a idx. If it is
+ * @c NULL or invalid, the program may crash.
+ *
+ * @since_tizen 2.3
+ *
+ * @param[in] array The array
+ * @param[in] idx The position of the data to set
+ * @param[in] data The data to set
+ *
+ */
static inline void eina_array_data_set(const Eina_Array *array,
unsigned int idx,
const void *data) EINA_ARG_NONNULL(1);
+
/**
* @brief Return the number of elements in an array.
*
- * @param array The array.
- * @return The number of elements.
+ * @details This function returns the number of elements in @p array (array->count). For
+ * performance reasons, there is no check of @p array. If it is
+ * @c NULL or invalid, the program may crash.
+ *
+ * @since_tizen 2.3
*
- * This function returns the number of elements in @p array (array->count). For
- * performance reasons, there is no check of @p array. If it is
- * @c NULL or invalid, the program may crash.
+ * @param[in] array The array.
+ * @return The number of elements.
*
* @deprecated use eina_array_count()
*/
@@ -405,74 +310,82 @@ static inline unsigned int eina_array_count_get(const Eina_Array *array) EINA_AR
/**
* @brief Return the number of elements in an array.
*
- * @param array The array.
- * @return The number of elements.
+ * @details This function returns the number of elements in @p array (array->count).
+ * For performance reasons, there is no check of @p array. If it is
+ * @c NULL or invalid, the program may crash.
*
- * This function returns the number of elements in @p array (array->count). For
- * performance reasons, there is no check of @p array. If it is
- * @c NULL or invalid, the program may crash.
+ * @since_tizen 2.3
+ *
+ * @param[in] array The array.
+ * @return The number of elements.
*/
static inline unsigned int eina_array_count(const Eina_Array *array) EINA_ARG_NONNULL(1) EINA_WARN_UNUSED_RESULT;
/**
- * @brief Get a new iterator associated to an array.
+ * @brief Returns a new iterator associated to an array.
+ *
+ * @details This function returns a newly allocated iterator associated to
+ * @a array. If @a array is @c NULL or the count member of @a array is
+ * less than or equal to 0, this function returns @c NULL. If the memory cannot
+ * be allocated, @c NULL is returned and #EINA_ERROR_OUT_OF_MEMORY is
+ * set. Otherwise, a valid iterator is returned.
*
- * @param array The array.
- * @return A new iterator.
+ * @since_tizen 2.3
+ *
+ * @param[in] array The array
+ * @return A new iterator
*
- * This function returns a newly allocated iterator associated to
- * @p array. If @p array is @c NULL or the count member of @p array is
- * less or equal than 0, this function returns @c NULL. If the memory can
- * not be allocated, @c NULL is returned. Otherwise, a valid iterator is returned.
*/
EAPI Eina_Iterator *eina_array_iterator_new(const Eina_Array *array) EINA_MALLOC EINA_ARG_NONNULL(1) EINA_WARN_UNUSED_RESULT;
/**
- * @brief Get a new accessor associated to an array.
+ * @brief Returns a new accessor associated to an array.
+ *
+ * @details This function returns a newly allocated accessor associated to
+ * @a array. If @a array is @c NULL or the count member of @a array is
+ * less than or equal to @c 0, this function returns @c NULL. If the memory cannot
+ * be allocated, @c NULL is returned and #EINA_ERROR_OUT_OF_MEMORY is
+ * set. Otherwise, a valid accessor is returned.
+ *
+ * @since_tizen 2.3
*
- * @param array The array.
- * @return A new accessor.
+ * @param[in] array The array
+ * @return A new accessor
*
- * This function returns a newly allocated accessor associated to
- * @p array. If @p array is @c NULL or the count member of @p array is
- * less or equal than 0, this function returns @c NULL. If the memory can
- * not be allocated, @c NULL is returned. Otherwise, a valid accessor is
- * returned.
*/
EAPI Eina_Accessor *eina_array_accessor_new(const Eina_Array *array) EINA_MALLOC EINA_ARG_NONNULL(1) EINA_WARN_UNUSED_RESULT;
/**
- * @brief Provide a safe way to iterate over an array
+ * @brief Provides a safe way to iterate over an array.
*
- * @param array The array to iterate over.
- * @param cb The callback to call for each item.
- * @param fdata The user data to pass to the callback.
- * @return #EINA_TRUE if it successfully iterate all items of the array.
+ * @details This function provides a safe way to iterate over an array. @a cb should
+ * return @c EINA_TRUE as long as you want the function to continue iterating,
+ * by returning @c EINA_FALSE it stops and returns @c EINA_FALSE as a result.
+ *
+ * @since_tizen 2.3
+ *
+ * @param[in] array The array to iterate over
+ * @param[in] cb The callback to call for each item
+ * @param[in] fdata The user data to pass to the callback
+ * @return @c EINA_TRUE if it successfully iterates all the items of the array, otherwise @c EINA_FALSE
*
- * This function provides a safe way to iterate over an array. @p cb should
- * return #EINA_TRUE as long as you want the function to continue iterating.
- * If @p cb returns #EINA_FALSE, iterations will stop and the function will also
- * return #EINA_FALSE.
*/
static inline Eina_Bool eina_array_foreach(Eina_Array *array,
Eina_Each_Cb cb,
void *fdata);
/**
* @def EINA_ARRAY_ITER_NEXT
- * @brief Macro to iterate over an array easily.
+ * @brief Definition of the macro to iterate over an array easily.
*
- * @param array The array to iterate over.
- * @param index The integer number that is increased while iterating.
- * @param item The data
- * @param iterator The iterator
+ * @details This macro allows the iteration over @a array in an easy way. It
+ * iterates from the first element to the last one. @a index is an
+ * integer that increases from 0 to the number of elements. @a item is
+ * the data of each element of @a array, so it is a pointer to a type
+ * chosen by the user. @a iterator is of type #Eina_Array_Iterator.
*
- * This macro allows the iteration over @p array in an easy way. It
- * iterates from the first element to the last one. @p index is an
- * integer that increases from 0 to the number of elements. @p item is
- * the data of each element of @p array, so it is a pointer to a type
- * chosen by the user. @p iterator is of type #Eina_Array_Iterator.
+ * @since_tizen 2.3
*
- * This macro can be used for freeing the data of an array, like in
- * the following example:
+ * @remarks This macro can be used for freeing the data of an array, like in
+ * the following example:
*
* @code
* Eina_Array *array;
@@ -487,6 +400,12 @@ static inline Eina_Bool eina_array_foreach(Eina_Array *array,
* EINA_ARRAY_ITER_NEXT(array, i, item, iterator)
* free(item);
* @endcode
+ *
+ * @param array The array to iterate over
+ * @param index The integer number that is increased while iterating
+ * @param item The data
+ * @param iterator The iterator
+ *
*/
#define EINA_ARRAY_ITER_NEXT(array, index, item, iterator) \
for (index = 0, iterator = (array)->data; \
@@ -499,12 +418,4 @@ static inline Eina_Bool eina_array_foreach(Eina_Array *array,
* @}
*/
-/**
- * @}
- */
-
-/**
- * @}
- */
-
#endif