Ne.app NeANT
The Ne.app NeANT User module of the NeANT distribution.
std_string.hpp
Go to the documentation of this file.
1// # This file is a part of toml++ and is subject to the the terms of the MIT license.
2// # Copyright (c) Mark Gillard <mark.gillard@outlook.com.au>
3// # See https://github.com/marzer/tomlplusplus/blob/master/LICENSE for the full license text.
4// SPDX-License-Identifier: MIT
5#pragma once
6
7#include "preprocessor.hpp"
9#include <string>
10#include <string_view>
12
13#if TOML_DOXYGEN || (defined(__cpp_char8_t) && __cpp_char8_t >= 201811 && \
14 defined(__cpp_lib_char8_t) && __cpp_lib_char8_t >= 201907)
15#define TOML_HAS_CHAR8 1
16#else
17#define TOML_HAS_CHAR8 0
18#endif
19
21
22namespace toml // non-abi namespace; this is not an error
23{
24using namespace std::string_literals;
25using namespace std::string_view_literals;
26} // namespace toml
27
28#if TOML_ENABLE_WINDOWS_COMPAT
29
33 std::string narrow(std::wstring_view);
34
37 std::wstring widen(std::string_view);
38
39#if TOML_HAS_CHAR8
40
43 std::wstring widen(std::u8string_view);
44
45#endif
46}
48
49#endif // TOML_ENABLE_WINDOWS_COMPAT
50
const char * widen(char *dst, const char *src)
const char * narrow(char *dst, const char *src)
#define TOML_EXPORTED_FREE_FUNCTION
An 'export' annotation to add to free functions. \detail Not defined by default.
The root namespace for all toml++ functions and types.
#define TOML_NODISCARD
#define TOML_IMPL_NAMESPACE_END
#define TOML_IMPL_NAMESPACE_START
TOML_ENABLE_WARNINGS
TOML_DISABLE_WARNINGS
Definition std_string.hpp:8