diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/attributes.h | 25 | ||||
-rw-r--r-- | src/base64.c | 2 | ||||
-rw-r--r-- | src/base64.h | 2 | ||||
-rw-r--r-- | src/byte_sink.h | 2 | ||||
-rw-r--r-- | src/byte_source.c | 2 | ||||
-rw-r--r-- | src/byte_source.h | 4 | ||||
-rw-r--r-- | src/env.c | 2 | ||||
-rw-r--r-- | src/n3.c | 6 | ||||
-rw-r--r-- | src/node.c | 5 | ||||
-rw-r--r-- | src/node.h | 3 | ||||
-rw-r--r-- | src/reader.c | 4 | ||||
-rw-r--r-- | src/reader.h | 10 | ||||
-rw-r--r-- | src/serd_internal.h | 2 | ||||
-rw-r--r-- | src/serdi.c | 11 | ||||
-rw-r--r-- | src/string.c | 5 | ||||
-rw-r--r-- | src/string_utils.h | 2 | ||||
-rw-r--r-- | src/system.h | 2 | ||||
-rw-r--r-- | src/uri.c | 8 | ||||
-rw-r--r-- | src/uri_utils.h | 2 | ||||
-rw-r--r-- | src/writer.c | 14 |
20 files changed, 66 insertions, 47 deletions
diff --git a/src/attributes.h b/src/attributes.h deleted file mode 100644 index 11c699f3..00000000 --- a/src/attributes.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2019-2023 David Robillard <d@drobilla.net> -// SPDX-License-Identifier: ISC - -#ifndef SERD_SRC_ATTRIBUTES_H -#define SERD_SRC_ATTRIBUTES_H - -#if defined(__GNUC__) -# define SERD_LOG_FUNC(fmt, arg1) __attribute__((format(printf, fmt, arg1))) -#else -# define SERD_LOG_FUNC(fmt, arg1) -#endif - -#ifdef __GNUC__ -# define SERD_MALLOC_FUNC __attribute__((malloc)) -#else -# define SERD_MALLOC_FUNC -#endif - -#ifdef __GNUC__ -# define SERD_NODISCARD __attribute__((warn_unused_result)) -#else -# define SERD_NODISCARD -#endif - -#endif // SERD_SRC_ATTRIBUTES_H diff --git a/src/base64.c b/src/base64.c index 13f08ab0..14f45b71 100644 --- a/src/base64.c +++ b/src/base64.c @@ -6,7 +6,7 @@ #include "serd_internal.h" #include "string_utils.h" -#include "serd/serd.h" +#include "serd/string.h" #include <stdbool.h> #include <stdint.h> diff --git a/src/base64.h b/src/base64.h index 21a6878c..d3e2b6e1 100644 --- a/src/base64.h +++ b/src/base64.h @@ -4,7 +4,7 @@ #ifndef SERD_SRC_BASE64_H #define SERD_SRC_BASE64_H -#include "serd/serd.h" +#include "serd/attributes.h" #include <stdbool.h> #include <stddef.h> diff --git a/src/byte_sink.h b/src/byte_sink.h index 39248c8c..0b4a83b1 100644 --- a/src/byte_sink.h +++ b/src/byte_sink.h @@ -7,7 +7,7 @@ #include "serd_internal.h" #include "system.h" -#include "serd/serd.h" +#include "serd/sink.h" #include <stddef.h> #include <string.h> diff --git a/src/byte_source.c b/src/byte_source.c index 72a2366e..b56e0102 100644 --- a/src/byte_source.c +++ b/src/byte_source.c @@ -5,8 +5,6 @@ #include "system.h" -#include "serd/serd.h" - #include <stdbool.h> #include <stdint.h> #include <string.h> diff --git a/src/byte_source.h b/src/byte_source.h index 218e47fa..b6cba5d4 100644 --- a/src/byte_source.h +++ b/src/byte_source.h @@ -4,7 +4,9 @@ #ifndef SERD_SRC_BYTE_SOURCE_H #define SERD_SRC_BYTE_SOURCE_H -#include "serd/serd.h" +#include "serd/attributes.h" +#include "serd/status.h" +#include "serd/stream.h" #include <assert.h> #include <stdbool.h> @@ -1,7 +1,7 @@ // Copyright 2011-2023 David Robillard <d@drobilla.net> // SPDX-License-Identifier: ISC -#include "serd/serd.h" +#include "serd/env.h" #include <stdbool.h> #include <stdio.h> @@ -8,7 +8,11 @@ #include "try.h" #include "uri_utils.h" -#include "serd/serd.h" +#include "serd/node.h" +#include "serd/reader.h" +#include "serd/statement.h" +#include "serd/status.h" +#include "serd/syntax.h" #include <assert.h> #include <stdbool.h> @@ -6,7 +6,10 @@ #include "base64.h" #include "string_utils.h" -#include "serd/serd.h" +#include "serd/buffer.h" +#include "serd/node.h" +#include "serd/string.h" +#include "serd/uri.h" #include <float.h> #include <math.h> @@ -4,7 +4,8 @@ #ifndef SERD_SRC_NODE_H #define SERD_SRC_NODE_H -#include "serd/serd.h" +#include "serd/attributes.h" +#include "serd/node.h" #include <stddef.h> diff --git a/src/reader.c b/src/reader.c index f34de787..00f5e73f 100644 --- a/src/reader.c +++ b/src/reader.c @@ -9,6 +9,10 @@ #include "serd_internal.h" +#include "serd/memory.h" +#include "serd/stream.h" +#include "serd/uri.h" + #include <errno.h> #include <stdarg.h> #include <stdint.h> diff --git a/src/reader.h b/src/reader.h index c0bf3765..e24bb31a 100644 --- a/src/reader.h +++ b/src/reader.h @@ -4,11 +4,17 @@ #ifndef SERD_SRC_READER_H #define SERD_SRC_READER_H -#include "attributes.h" #include "byte_source.h" #include "stack.h" -#include "serd/serd.h" +#include "serd/attributes.h" +#include "serd/error.h" +#include "serd/node.h" +#include "serd/reader.h" +#include "serd/sink.h" +#include "serd/statement.h" +#include "serd/status.h" +#include "serd/syntax.h" #include <assert.h> #include <stdbool.h> diff --git a/src/serd_internal.h b/src/serd_internal.h index 7fcae691..b3221ae7 100644 --- a/src/serd_internal.h +++ b/src/serd_internal.h @@ -4,7 +4,7 @@ #ifndef SERD_SRC_SERD_INTERNAL_H #define SERD_SRC_SERD_INTERNAL_H -#include "serd/serd.h" +#include "serd/error.h" #include <stdio.h> diff --git a/src/serdi.c b/src/serdi.c index 421e5df8..27e6d782 100644 --- a/src/serdi.c +++ b/src/serdi.c @@ -4,7 +4,16 @@ #include "serd_config.h" #include "string_utils.h" -#include "serd/serd.h" +#include "serd/attributes.h" +#include "serd/env.h" +#include "serd/error.h" +#include "serd/node.h" +#include "serd/reader.h" +#include "serd/sink.h" +#include "serd/status.h" +#include "serd/syntax.h" +#include "serd/uri.h" +#include "serd/writer.h" #ifdef _WIN32 # ifdef _MSC_VER diff --git a/src/string.c b/src/string.c index b0ffe51a..4d8f4f09 100644 --- a/src/string.c +++ b/src/string.c @@ -3,7 +3,10 @@ #include "string_utils.h" -#include "serd/serd.h" +#include "serd/memory.h" +#include "serd/node.h" +#include "serd/status.h" +#include "serd/string.h" #include <assert.h> #include <math.h> diff --git a/src/string_utils.h b/src/string_utils.h index 723df710..86795dcb 100644 --- a/src/string_utils.h +++ b/src/string_utils.h @@ -4,7 +4,7 @@ #ifndef SERD_SRC_STRING_UTILS_H #define SERD_SRC_STRING_UTILS_H -#include "serd/serd.h" +#include "serd/node.h" #include <stdbool.h> #include <stddef.h> diff --git a/src/system.h b/src/system.h index 1a749bae..081b60c4 100644 --- a/src/system.h +++ b/src/system.h @@ -4,7 +4,7 @@ #ifndef SERD_SRC_SYSTEM_H #define SERD_SRC_SYSTEM_H -#include "attributes.h" +#include "serd/attributes.h" #include <stdio.h> @@ -4,7 +4,11 @@ #include "string_utils.h" #include "uri_utils.h" -#include "serd/serd.h" +#include "serd/buffer.h" +#include "serd/status.h" +#include "serd/stream.h" +#include "serd/string_view.h" +#include "serd/uri.h" #include <stdbool.h> #include <stdint.h> @@ -268,7 +272,7 @@ serd_uri_resolve(const SerdURIView* const r, return; } - t->path_base.buf = NULL; + t->path_base.buf = ""; t->path_base.len = 0; if (r->scheme.len) { *t = *r; diff --git a/src/uri_utils.h b/src/uri_utils.h index b275cf5f..3974b5ce 100644 --- a/src/uri_utils.h +++ b/src/uri_utils.h @@ -4,7 +4,7 @@ #ifndef SERD_SRC_URI_UTILS_H #define SERD_SRC_URI_UTILS_H -#include "serd/serd.h" +#include "serd/attributes.h" #include "string_utils.h" diff --git a/src/writer.c b/src/writer.c index eea85ddf..612c2620 100644 --- a/src/writer.c +++ b/src/writer.c @@ -1,7 +1,6 @@ // Copyright 2011-2023 David Robillard <d@drobilla.net> // SPDX-License-Identifier: ISC -#include "attributes.h" #include "byte_sink.h" #include "serd_internal.h" #include "stack.h" @@ -9,7 +8,18 @@ #include "try.h" #include "uri_utils.h" -#include "serd/serd.h" +#include "serd/attributes.h" +#include "serd/buffer.h" +#include "serd/env.h" +#include "serd/error.h" +#include "serd/node.h" +#include "serd/statement.h" +#include "serd/status.h" +#include "serd/stream.h" +#include "serd/string_view.h" +#include "serd/syntax.h" +#include "serd/uri.h" +#include "serd/writer.h" #include <errno.h> #include <stdarg.h> |