aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2016-03-15 23:37:09 -0400
committerDavid Robillard <d@drobilla.net>2021-03-07 15:32:23 -0500
commita35d0782c0fb5a52d77dede6b0bffee4e7fdefbd (patch)
treef56a4f4b75361c9268ab2b58b1f0692a7bb2d32f /include
parenta7be33a7640ee51066c41eded5812d9cee5ad27e (diff)
downloadserd-a35d0782c0fb5a52d77dede6b0bffee4e7fdefbd.tar.gz
serd-a35d0782c0fb5a52d77dede6b0bffee4e7fdefbd.tar.bz2
serd-a35d0782c0fb5a52d77dede6b0bffee4e7fdefbd.zip
Remove useless character counting
Diffstat (limited to 'include')
-rw-r--r--include/serd/serd.h7
1 files changed, 2 insertions, 5 deletions
diff --git a/include/serd/serd.h b/include/serd/serd.h
index c60bf465..5d5803d0 100644
--- a/include/serd/serd.h
+++ b/include/serd/serd.h
@@ -187,7 +187,6 @@ typedef uint32_t SerdNodeFlags;
typedef struct {
const uint8_t* SERD_NULLABLE buf; ///< Value string
size_t n_bytes; ///< Size in bytes (excluding null)
- size_t n_chars; ///< String length (excluding null)
SerdNodeFlags flags; ///< Node flags (string properties)
SerdType type; ///< Node type
} SerdNode;
@@ -269,15 +268,13 @@ serd_strerror(SerdStatus status);
/**
Measure a UTF-8 string.
- @return Length of `str` in characters (except NULL).
+ @return Length of `str` in bytes.
@param str A null-terminated UTF-8 string.
- @param n_bytes (Output) Set to the size of `str` in bytes (except NULL).
@param flags (Output) Set to the applicable flags.
*/
SERD_API
size_t
serd_strlen(const uint8_t* SERD_NONNULL str,
- size_t* SERD_NULLABLE n_bytes,
SerdNodeFlags* SERD_NULLABLE flags);
/**
@@ -418,7 +415,7 @@ serd_uri_serialise_relative(const SerdURI* SERD_NONNULL uri,
@{
*/
-static const SerdNode SERD_NODE_NULL = {NULL, 0, 0, 0, SERD_NOTHING};
+static const SerdNode SERD_NODE_NULL = {NULL, 0, 0, SERD_NOTHING};
/**
Make a (shallow) node from `str`.