c语言头文件cstring,头文件 <string.h> <cstring> <string> 区别

c语言头文件cstring,头文件 <string.h> <cstring> <string> 区别/**@filecstring*ThisisaStandardC++Libraryfile.Youshould@c\#includethisfile*inyourprograms,ratherthananyofthe@a*.himplementationfiles.**ThisistheC++versionoftheSt…

大家好,又见面了,我是你们的朋友全栈君。如果您正在找激活码,请点击查看最新教程,关注关注公众号 “全栈程序员社区” 获取激活教程,可能之前旧版本教程已经失效.最新Idea2022.1教程亲测有效,一键激活。

Jetbrains全系列IDE使用 1年只要46元 售后保障 童叟无欺

/** @file cstring

* This is a Standard C++ Library file. You should @c \#include this file

* in your programs, rather than any of the @a *.h implementation files.

*

* This is the C++ version of the Standard C Library header @c string.h,

* and its contents are (mostly) the same as that header, but are all

* contained in the namespace @c std (except for names which are defined

* as macros in C).*/

//

//ISO C++ 14882: 20.4.6 C library//

#pragma GCC system_header#include#include#ifndef _GLIBCXX_CSTRING#define _GLIBCXX_CSTRING 1

//Get rid of those macros defined in in lieu of real functions.

#undef memchr

#undef memcmp

#undef memcpy

#undef memmove

#undef memset

#undef strcat

#undef strchr

#undef strcmp

#undef strcoll

#undef strcpy

#undef strcspn

#undef strerror

#undef strlen

#undef strncat

#undef strncmp

#undef strncpy

#undef strpbrk

#undef strrchr

#undef strspn

#undef strstr

#undef strtok

#undef strxfrm

namespace std _GLIBCXX_VISIBILITY(default)

{

_GLIBCXX_BEGIN_NAMESPACE_VERSIONusing::memchr;using::memcmp;using::memcpy;using::memmove;using::memset;using::strcat;using::strcmp;using::strcoll;using::strcpy;using::strcspn;using::strerror;using::strlen;using::strncat;using::strncmp;using::strncpy;using::strspn;using::strtok;using::strxfrm;using::strchr;using::strpbrk;using::strrchr;using::strstr;

#ifndef __CORRECT_ISO_CPP_STRING_H_PROTO

inlinevoid*memchr(void* __s, int__c, size_t __n)

{return__builtin_memchr(__s, __c, __n); }

inlinechar*strchr(char* __s, int__n)

{return__builtin_strchr(__s, __n); }

inlinechar*strpbrk(char* __s1, const char*__s2)

{return__builtin_strpbrk(__s1, __s2); }

inlinechar*strrchr(char* __s, int__n)

{return__builtin_strrchr(__s, __n); }

inlinechar*strstr(char* __s1, const char*__s2)

{return__builtin_strstr(__s1, __s2); }#endif_GLIBCXX_END_NAMESPACE_VERSION

}//namespace

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/194559.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • 【手把手】制作一个简单的HTML网页

    【手把手】制作一个简单的HTML网页新建一个html文件:我要给body添加一些样式,就在head元素上挂载一个style元素。然后,写样式表:效果:这样的话,我们就可以看到body部分了。现在,我给body添加一点padding。页面上看不出区别,让我们打开F12,看一下现在的body变成了什么样子。示意图:从图中可以看出,body元素分为三层,最里面的一层,就是520×500的那部分,这个叫做内部真实空间,也就是说,你可以在里面添加其他元素,比如div元素,p元素,a元素等等。然后中间的一层就是paddin

    2022年7月27日
    20
  • 二进制数的运算方法

    二进制数的运算方法1.二进制数的算术运算二进制数的算术运算包括:加、减、乘、除四则运算,下面分别予以介绍。(1)二进制数的加法根据“逢二进一”规则,二进制数加法的法则为:0+0=00+1=1+0=11+1=0 (进位为1)1+1+1=1(进位为1)例如:1110和1011相加过程如下:(2)二进制数的减法根据“借一有二”的规则,二进制数减法的法则为:

    2022年6月29日
    21
  • youtube8m 第四届_youtube怎么上

    youtube8m 第四届_youtube怎么上今天进入前十

    2022年5月3日
    33
  • Jenkins的详细安装及使用

    Jenkins的详细安装及使用操作环境:Windows一、环境准备1安装JDK&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;nbsp;本文采用jdk-8u111-windows-x64.exe;2配置tomcat&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;nbs

    2022年5月28日
    71
  • vue-cli创建的项目中引入第三方库报错 ‘caller’, ‘calle’, and ‘arguments’ properties may not be……

    vue-cli创建的项目中引入第三方库报错 ‘caller’, ‘calle’, and ‘arguments’ properties may not be……

    2021年10月11日
    46
  • 求图的连通分量

    求图的连通分量题目 输出无向连通图各个连通分量 输入描述 输入文件中包含多个测试数据 每个测试数据的格式为 第 1 行为两个整数 n 和 m 分别表示顶点个数和边数 然后有 m 行 每行表示一条边 为这条边的两个顶点的序号 顶点序号从 1 开始计起 假定无向图是连通的 可能存在割点 也可能没有割点 n m 0 时表示输入结束 输出描述 对每个测试数据 以 uv 的形式依次输出各连通分量中的每条边 每

    2025年7月30日
    3

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号