From 14f1d39b4180475a5fa9030fccf95fdc8b693c09 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 19 Jun 2018 09:39:48 -0400 Subject: Separate style enum from style flags types --- src/serdi.c | 4 ++-- src/writer.c | 40 ++++++++++++++++++++-------------------- 2 files changed, 22 insertions(+), 22 deletions(-) (limited to 'src') diff --git a/src/serdi.c b/src/serdi.c index fc3efc04..8939ae3b 100644 --- a/src/serdi.c +++ b/src/serdi.c @@ -205,7 +205,7 @@ main(int argc, char** argv) SerdWorld* world = serd_world_new(); SerdEnv* env = serd_env_new(base); - int output_style = 0; + SerdStyleFlags output_style = 0; if (output_syntax == SERD_NTRIPLES || ascii) { output_style |= SERD_STYLE_ASCII; } else if (output_syntax == SERD_TURTLE) { @@ -227,7 +227,7 @@ main(int argc, char** argv) SerdWriter* writer = serd_writer_new(world, output_syntax, - (SerdStyle)output_style, + output_style, env, (SerdWriteFunc)fwrite, out_fd); diff --git a/src/writer.c b/src/writer.c index 4b5b1245..1868b106 100644 --- a/src/writer.c +++ b/src/writer.c @@ -87,25 +87,25 @@ static const SepRule rules[] = { }; struct SerdWriterImpl { - SerdWorld* world; - SerdSink iface; - SerdSyntax syntax; - SerdStyle style; - SerdEnv* env; - SerdNode* root_node; - SerdURI root_uri; - SerdStack anon_stack; - SerdByteSink byte_sink; - SerdErrorSink error_sink; - void* error_handle; - WriteContext context; - SerdNode* list_subj; - unsigned list_depth; - unsigned indent; - char* bprefix; - size_t bprefix_len; - Sep last_sep; - bool empty; + SerdWorld* world; + SerdSink iface; + SerdSyntax syntax; + SerdStyleFlags style; + SerdEnv* env; + SerdNode* root_node; + SerdURI root_uri; + SerdStack anon_stack; + SerdByteSink byte_sink; + SerdErrorSink error_sink; + void* error_handle; + WriteContext context; + SerdNode* list_subj; + unsigned list_depth; + unsigned indent; + char* bprefix; + size_t bprefix_len; + Sep last_sep; + bool empty; }; typedef enum { @@ -867,7 +867,7 @@ serd_writer_finish(SerdWriter* writer) SerdWriter* serd_writer_new(SerdWorld* world, SerdSyntax syntax, - SerdStyle style, + SerdStyleFlags style, SerdEnv* env, SerdWriteFunc ssink, void* stream) -- cgit v1.2.1