aboutsummaryrefslogtreecommitdiffstats
path: root/include/serd/world.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2022-12-19 20:26:13 -0500
committerDavid Robillard <d@drobilla.net>2023-12-02 18:49:07 -0500
commit3d79b6ee36b250644e6cf70eee8e3076d94cbb7f (patch)
tree0f734bfcfd278d6eef5ca0e82c008b7f2a6f7bba /include/serd/world.h
parent7fb4c5264b91d5a5ce9f13a9fb4308088b31fcd4 (diff)
downloadserd-3d79b6ee36b250644e6cf70eee8e3076d94cbb7f.tar.gz
serd-3d79b6ee36b250644e6cf70eee8e3076d94cbb7f.tar.bz2
serd-3d79b6ee36b250644e6cf70eee8e3076d94cbb7f.zip
Use Zix attributes directly
Diffstat (limited to 'include/serd/world.h')
-rw-r--r--include/serd/world.h20
1 files changed, 11 insertions, 9 deletions
diff --git a/include/serd/world.h b/include/serd/world.h
index b4849fa2..4c51df73 100644
--- a/include/serd/world.h
+++ b/include/serd/world.h
@@ -8,6 +8,8 @@
#include "serd/error.h"
#include "serd/node.h"
#include "serd/status.h"
+#include "zix/allocator.h"
+#include "zix/attributes.h"
#include <stddef.h>
@@ -34,12 +36,12 @@ typedef struct {
It is safe to use multiple worlds in one process, though no objects can be
shared between worlds.
*/
-SERD_MALLOC_API SerdWorld* SERD_ALLOCATED
+SERD_MALLOC_API SerdWorld* ZIX_ALLOCATED
serd_world_new(void);
/// Free `world`
SERD_API void
-serd_world_free(SerdWorld* SERD_NULLABLE world);
+serd_world_free(SerdWorld* ZIX_NULLABLE world);
/**
Return the current resource limits.
@@ -50,7 +52,7 @@ serd_world_free(SerdWorld* SERD_NULLABLE world);
most data.
*/
SERD_API SerdLimits
-serd_world_limits(const SerdWorld* SERD_NONNULL world);
+serd_world_limits(const SerdWorld* ZIX_NONNULL world);
/**
Set the current resource limits.
@@ -60,7 +62,7 @@ serd_world_limits(const SerdWorld* SERD_NONNULL world);
other function like serd_reader_new() that uses the current limits.
*/
SERD_API SerdStatus
-serd_world_set_limits(SerdWorld* SERD_NONNULL world, SerdLimits limits);
+serd_world_set_limits(SerdWorld* ZIX_NONNULL world, SerdLimits limits);
/**
Return a unique blank node.
@@ -68,8 +70,8 @@ serd_world_set_limits(SerdWorld* SERD_NONNULL world, SerdLimits limits);
The returned node is valid only until the next time serd_world_get_blank()
is called or the world is destroyed.
*/
-SERD_API const SerdNode* SERD_NONNULL
-serd_world_get_blank(SerdWorld* SERD_NONNULL world);
+SERD_API const SerdNode* ZIX_NONNULL
+serd_world_get_blank(SerdWorld* ZIX_NONNULL world);
/**
Set a function to be called when errors occur.
@@ -78,9 +80,9 @@ serd_world_get_blank(SerdWorld* SERD_NONNULL world);
no error function is set, errors are printed to stderr.
*/
SERD_API void
-serd_world_set_error_func(SerdWorld* SERD_NONNULL world,
- SerdErrorFunc SERD_NULLABLE error_func,
- void* SERD_NULLABLE handle);
+serd_world_set_error_func(SerdWorld* ZIX_NONNULL world,
+ SerdErrorFunc ZIX_NULLABLE error_func,
+ void* ZIX_NULLABLE handle);
/**
@}