tetl 0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
wcsncpy.hpp
Go to the documentation of this file.
1// SPDX-License-Identifier: BSL-1.0
2
3#ifndef TETL_CWCHAR_WCSNCPY_HPP
4#define TETL_CWCHAR_WCSNCPY_HPP
5
9
10namespace etl {
11
23constexpr auto wcsncpy(wchar_t* dest, wchar_t const* src, etl::size_t const count) -> wchar_t*
24{
25 TETL_PRECONDITION(dest != nullptr);
26 TETL_PRECONDITION(src != nullptr);
27 return etl::detail::strncpy(dest, src, count);
28}
29
30} // namespace etl
31
32#endif // TETL_CWCHAR_WCSNCPY_HPP
#define TETL_PRECONDITION(...)
Definition check.hpp:16
constexpr auto count(InputIt first, InputIt last, T const &value) -> typename iterator_traits< InputIt >::difference_type
Returns the number of elements in the range [first, last) satisfying specific criteria....
Definition count.hpp:21
Definition adjacent_find.hpp:8
constexpr auto wcsncpy(wchar_t *dest, wchar_t const *src, etl::size_t const count) -> wchar_t *
Copies at most count characters of the wide string pointed to by src (including the terminating null ...
Definition wcsncpy.hpp:23
TETL_BUILTIN_SIZET size_t
etl::size_t is the unsigned integer type of the result of the sizeof operator.
Definition size_t.hpp:14