文章分类 -  c++

摘要:rpc模块 rpc.h rpc调用结果 template<typename T> struct return_type { using type = T; }; template<> struct return_type<void> { using type = int8_t; }; /** * @ 阅读全文
posted @ 2023-11-21 15:05 DavidJIAN 阅读(29) 评论(0) 推荐(0)
摘要:C++ 面向對象程序設計-part11.Header(头文件)的防卫式声明2.Header(头文件)的布局2.inline(内联)函数3.access level(访问级别)4.constructo(ctor,构造函数)5.const member functions(常量成员函数)6.参数传递:p 阅读全文
posted @ 2022-10-16 20:56 DavidJIAN 阅读(36) 评论(0) 推荐(0)
摘要:C++(malloc/free和new/delete) 用于测试的类A /** * @brief 用于检测new和delete对构造函数和析构函数 * */ class A{ public: A(){ std::cout<<"call constructor:A()"<<std::endl; } ~ 阅读全文
posted @ 2022-08-15 17:49 DavidJIAN 阅读(67) 评论(0) 推荐(0)