std:: wmemmove
| Localization library | |||||||||||||||||||||||||
| Regular expressions library (C++11) | |||||||||||||||||||||||||
| Formatting library (C++20) | |||||||||||||||||||||||||
| Null-terminated sequence utilities | |||||||||||||||||||||||||
| Byte strings | |||||||||||||||||||||||||
| Multibyte strings | |||||||||||||||||||||||||
| Wide strings | |||||||||||||||||||||||||
| Primitive numeric conversions | |||||||||||||||||||||||||
|
|||||||||||||||||||||||||
| Text encoding identifications | |||||||||||||||||||||||||
|
|||||||||||||||||||||||||
| Functions | ||||||||||||||||||||||||||
| Character classification | ||||||||||||||||||||||||||
| Character manipulation | ||||||||||||||||||||||||||
| Conversions to numeric formats | ||||||||||||||||||||||||||
|
|
|||||||||||||||||||||||||
| String manipulation | ||||||||||||||||||||||||||
| String examination | ||||||||||||||||||||||||||
| Array manipulation | ||||||||||||||||||||||||||
|
헤더 파일에 정의됨
<cwchar>
|
||
|
wchar_t
*
wmemmove
(
wchar_t
*
dest,
const
wchar_t
*
src,
std::
size_t
count
)
;
|
||
정확히 count 개의 연속된 와이드 문자를 src 가 가리키는 와이드 문자 배열에서 dest 가 가리키는 와이드 문자 배열로 복사합니다.
만약 count 가 0이면, 함수는 아무 작업도 수행하지 않습니다.
배열들은 겹칠 수 있습니다: 복사는 와이드 문자가 임시 와이드 문자 배열에 복사된 후 임시 배열에서 dest 로 복사되는 것처럼 수행됩니다.
목차매개변수
반환값dest 의 복사본을 반환합니다. 참고 사항이 함수는 로캘에 민감하지 않으며 복사하는 wchar_t 객체의 값에 주의를 기울이지 않습니다: null 문자와 유효하지 않은 문자들도 모두 복사됩니다. 예제
이 코드 실행
#include <clocale> #include <cwchar> #include <iostream> #include <locale> int main() { std::setlocale(LC_ALL, "en_US.utf8"); std::wcout.imbue(std::locale("en_US.utf8")); wchar_t str[] = L"αβγδεζηθικλμνξοπρστυφχψω"; std::wcout << str << '\n'; std::wmemmove(str + 4, str + 3, 3); // copy from [δεζ] to [εζη] std::wcout << str << '\n'; } 가능한 출력: αβγδεζηθικλμνξοπρστυφχψω αβγδδεζθικλμνξοπρστυφχψω 참고
| |||||||||||||||||||||||