diff options
author | David Robillard <d@drobilla.net> | 2019-10-19 03:29:26 +0200 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2019-12-20 10:26:55 -0500 |
commit | 81d2bf7da621a07fb0f7cbb699cc82dbad4d59d1 (patch) | |
tree | dcc3be3ec4ed708b34beeeb37cca5d39e934057b | |
parent | 5e54264bf9a545d5a95ee63c04fd994458a35fb9 (diff) | |
download | serd-81d2bf7da621a07fb0f7cbb699cc82dbad4d59d1.tar.gz serd-81d2bf7da621a07fb0f7cbb699cc82dbad4d59d1.tar.bz2 serd-81d2bf7da621a07fb0f7cbb699cc82dbad4d59d1.zip |
Move MIN macro to int_math.h
-rw-r--r-- | src/base64.c | 2 | ||||
-rw-r--r-- | src/byte_sink.c | 2 | ||||
-rw-r--r-- | src/int_math.h | 2 | ||||
-rw-r--r-- | src/n3.c | 2 | ||||
-rw-r--r-- | src/namespaces.h (renamed from src/serd_internal.h) | 10 | ||||
-rw-r--r-- | src/node.c | 2 | ||||
-rw-r--r-- | src/reader.c | 2 | ||||
-rw-r--r-- | src/static_nodes.h | 2 | ||||
-rw-r--r-- | src/world.c | 2 | ||||
-rw-r--r-- | wscript | 2 |
10 files changed, 13 insertions, 15 deletions
diff --git a/src/base64.c b/src/base64.c index 9fb28019..855d62c0 100644 --- a/src/base64.c +++ b/src/base64.c @@ -14,7 +14,7 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include "serd_internal.h" +#include "int_math.h" #include "string_utils.h" #include "serd/serd.h" diff --git a/src/byte_sink.c b/src/byte_sink.c index 1e07189d..b8cba4e7 100644 --- a/src/byte_sink.c +++ b/src/byte_sink.c @@ -14,7 +14,7 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include "serd_internal.h" +#include "int_math.h" #include "system.h" #include "serd/serd.h" diff --git a/src/int_math.h b/src/int_math.h index 05c3abaa..b18b1324 100644 --- a/src/int_math.h +++ b/src/int_math.h @@ -19,6 +19,8 @@ #include <stdint.h> +#define MIN(x, y) ((x) < (y) ? (x) : (y)) + static const uint64_t POW10[] = {1ull, 10ull, 100ull, @@ -15,9 +15,9 @@ */ #include "byte_source.h" +#include "namespaces.h" #include "node.h" #include "reader.h" -#include "serd_internal.h" #include "stack.h" #include "string_utils.h" #include "uri_utils.h" diff --git a/src/serd_internal.h b/src/namespaces.h index fda651ae..f298184a 100644 --- a/src/serd_internal.h +++ b/src/namespaces.h @@ -14,14 +14,10 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#ifndef SERD_INTERNAL_H -#define SERD_INTERNAL_H +#ifndef SERD_NAMESPACES_H +#define SERD_NAMESPACES_H #define NS_XSD "http://www.w3.org/2001/XMLSchema#" #define NS_RDF "http://www.w3.org/1999/02/22-rdf-syntax-ns#" -#ifndef MIN -# define MIN(a, b) (((a) < (b)) ? (a) : (b)) -#endif - -#endif // SERD_INTERNAL_H +#endif // SERD_NAMESPACES_H @@ -16,7 +16,7 @@ #include "node.h" -#include "serd_internal.h" +#include "namespaces.h" #include "static_nodes.h" #include "string_utils.h" #include "system.h" diff --git a/src/reader.c b/src/reader.c index f247411a..c407e6ba 100644 --- a/src/reader.c +++ b/src/reader.c @@ -17,9 +17,9 @@ #include "reader.h" #include "byte_source.h" +#include "namespaces.h" #include "node.h" #include "serd/serd.h" -#include "serd_internal.h" #include "stack.h" #include "statement.h" #include "system.h" diff --git a/src/static_nodes.h b/src/static_nodes.h index 42343d0d..056ff3dc 100644 --- a/src/static_nodes.h +++ b/src/static_nodes.h @@ -17,8 +17,8 @@ #ifndef SERD_STATIC_NODES_H #define SERD_STATIC_NODES_H +#include "namespaces.h" #include "node.h" -#include "serd_internal.h" typedef struct StaticNode { SerdNode node; diff --git a/src/world.c b/src/world.c index 48d97da4..36444987 100644 --- a/src/world.c +++ b/src/world.c @@ -19,9 +19,9 @@ #include "world.h" #include "cursor.h" +#include "namespaces.h" #include "node.h" #include "serd_config.h" -#include "serd_internal.h" #include <errno.h> #include <stdarg.h> @@ -265,7 +265,7 @@ def amalgamate(ctx): amalgamation.write('/* This is amalgamated code, do not edit! */\n') amalgamation.write('#include "serd.h"\n\n') - for header_path in ['src/serd_internal.h', + for header_path in ['src/namespaces.h', 'src/byte_sink.h', 'src/byte_source.h', 'src/stack.h', |