CString简单的C字符串操作函数
字符串该项目是为学习目的而开发的。我开发这个用于C字符串操作的实验。如果您想使用此代码,请自行承担风险。
用法代码示例:
#include \"cstring.h\"
//....
t_cstring *s = cstring_create();
// 将初始值添加到字符串
cstring_assign(s, \"This a fake message.\"); // 或者 cstring_add(s, \"This a fake message.\");
// 串联字符串
cstring_add(s, \"This part will be joined.\");
// 使用后释放内存
cstring_delete(s);
下载地址
用户评论