tetl
0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
memmove.hpp
Go to the documentation of this file.
1
// SPDX-License-Identifier: BSL-1.0
2
// SPDX-FileCopyrightText: Copyright (C) 2019 Tobias Hienzsch
3
4
#
ifndef
TETL_CSTRING_MEMMOVE_HPP
5
#
define
TETL_CSTRING_MEMMOVE_HPP
6
7
#
include
<
etl
/
_config
/
all
.
hpp
>
8
9
#
include
<
etl
/
_contracts
/
check
.
hpp
>
10
#
include
<
etl
/
_cstddef
/
size_t
.
hpp
>
11
#
include
<
etl
/
_strings
/
cstr
.
hpp
>
12
13
namespace
etl
{
14
15
/// Copy the first n bytes pointed to by src to the buffer pointed to by
16
/// dest. Source and destination may overlap.
17
/// \ingroup cstring
18
inline
auto
memmove
(
void
* dest,
void
const
* src,
etl
::size_t count) ->
void
*
19
{
20
TETL_PRECONDITION(dest !=
nullptr
);
21
TETL_PRECONDITION(src !=
nullptr
);
22
#
if
__has_builtin
(
__builtin_memmove
)
23
return
__builtin_memmove(dest, src, count);
24
#
else
25
return
etl::detail::memmove<
unsigned
char
>(dest, src, count);
26
#
endif
27
}
28
29
}
// namespace etl
30
#
endif
// TETL_CSTRING_MEMMOVE_HPP
etl::memmove
auto memmove(void *dest, void const *src, etl::size_t count) -> void *
Copy the first n bytes pointed to by src to the buffer pointed to by dest. Source and destination may...
Definition
memmove.hpp:18
etl
Definition
adjacent_find.hpp:9
include
etl
_cstring
memmove.hpp
Generated on Sat Sep 20 2025 23:50:44 for tetl by
1.9.8