memchr
来自cppreference.com
|
|
该页由英文版wiki使用Google Translate机器翻译而来。
该翻译可能存在错误或用词不当。鼠标停留在文本上可以看到原版本。你可以帮助我们修正错误或改进翻译。参见说明请点击这里. |
| 在头文件 <string.h> 中定义
|
||
| const void* memchr( const void* ptr, int ch, size_t count ); |
||
| void* memchr( void* ptr, int ch, size_t count ); |
||
ch,并找到该值在第一次出现的的初始unsigned char字符(每个解释为count)的对象所指向的unsigned char转换ptr. 原文:
Converts
ch to unsigned char and locates the first occurrence of that value in the initial count characters (each interpreted as unsigned char) of the object pointed to by ptr. 目录 |
[编辑] 参数
| ptr | - | 要检查的对象的指针
原文: pointer to the object to be examined |
| ch | - | 搜索字符
|
| count | - | 检查的字符数
|
[编辑] 返回值
如果没有这样的字符的指针的位置的字符,或NULL发现.
原文:
Pointer to the location of the character, or NULL if no such character is found.
[编辑] 示例
| 本章尚未完成 原因:暂无示例 |
[编辑] 另请参阅
| 找到第一个出现的字符 原文: finds the first occurrence of a character (函数) | |
| C++ documentation for memchr
| |