gibaseinfo: Add initialiser macro for GIAttributeIter

Makes it a little easier to use.

Signed-off-by: Philip Withnall <pwithnall@gnome.org>
This commit is contained in:
Philip Withnall
2024-01-18 12:27:46 +00:00
parent 57d64b111f
commit 9aea530ac0
4 changed files with 15 additions and 5 deletions

View File

@@ -48,6 +48,16 @@ typedef struct {
void *_dummy[4];
} GIAttributeIter;
/**
* GI_ATTRIBUTE_ITER_INIT:
*
* Initialise a stack-allocated [type@GIRepository.AttributeIter] to a value
* suitable for passing to the first call to an iterate function.
*
* Since: 2.80
*/
#define GI_ATTRIBUTE_ITER_INIT { NULL, { NULL, } }
#define GI_TYPE_BASE_INFO (gi_base_info_get_type ())
/**