2 * Copyright (c) 2014-2020 Pavel Kalvoda <me@pavelkalvoda.com>
4 * libcbor is free software; you can redistribute it and/or modify
5 * it under the terms of the MIT license. See LICENSE for details.
8 #ifndef LIBCBOR_UNICODE_H
9 #define LIBCBOR_UNICODE_H
11 #include "cbor/common.h"
17 enum _cbor_unicode_status_error { _CBOR_UNICODE_OK, _CBOR_UNICODE_BADCP };
19 /** Signals unicode validation error and possibly its location */
20 struct _cbor_unicode_status {
21 enum _cbor_unicode_status_error status;
26 uint64_t _cbor_unicode_codepoint_count(cbor_data source, uint64_t source_length,
27 struct _cbor_unicode_status* status);
33 #endif // LIBCBOR_UNICODE_H