From af81ace5f5a8f4bb0df93dd937395c65e92a5b6a Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sat, 10 Oct 2020 12:31:29 +0200 Subject: Add SERD_READ_EXACT_BLANKS flag This allows suppressing the blank node ID clashing mechanism to read blank IDs exactly as they appear in the input, even if they match the scheme used to generate blank node IDs internally. --- src/n3.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/n3.c b/src/n3.c index 517dce8f..14f5aec1 100644 --- a/src/n3.c +++ b/src/n3.c @@ -1090,7 +1090,7 @@ read_BLANK_NODE_LABEL(SerdReader* const reader, *ate_dot = true; } - if (fancy_syntax(reader)) { + if (fancy_syntax(reader) && !(reader->flags & SERD_READ_EXACT_BLANKS)) { if (is_digit(buf[reader->bprefix_len + 1])) { if ((buf[reader->bprefix_len]) == 'b') { buf[reader->bprefix_len] = 'B'; // Prevent clash -- cgit v1.2.1