在XX公司工作第二天,维护已有代码
2024-08-29 20:46:55
根据《C++ More Exception》所述的规则:
Rule #1: Never write using-directives in header files.
Rule #2: Never write namespace using-declarations in header files.
Rule #3: In implementation files, never use a using-declaration or a using-directive before #include directive.
Rule #4: Use C headers with the new style #include <cheader> instead of the old style #include <header.h>.
1.今天我把我负责的代码全部头文件里的using命令和声明全部移动到实现文件里,并在实现文件里将using放置在全部头文件的后面。
2.去除了关于std空间的前向声明
3.给变量起了一个更好的名字
备注一下:前向声明其它命名空间形式例如以下
namespace android{
class TouchInputMapper; (类)
template <typename T> class Singleton;(模版)
}
最新文章
- java学习中一些疑惑解答(2)
- Jsoup开发网站客户端第二篇,图片轮播,ScrollView兼容ListView
- Android课程---优化ListView列表视图
- XE2编译出来的DLL的DLLMain的退出地方用到了halt0
- 基于spark实现表的join操作
- C# 数据类型映射 (SQLite,MySQL,MSSQL,Oracle)
- 深入理解Oracle的imp/exp 和各版本之间的规则
- uva 10986 - Sending email(最短路Dijkstra)
- C++_基础_C与C++的区别
- 批处理bat脚本编写(附详细例子)
- Git学习笔记(一)创建版本库并添加文件
- 项目管理之 Git 管理软件 SourceTree for Mac
- 批量将webp格式的图片转成png的图片 https://cn.office-converter.com/WEBP-to-PNG
- Python3 的序列
- alpha冲刺第十天
- C语言博客作业--嵌套循环
- [CSDN_Markdown]Markdown基本语法2
- ";《算法导论》之‘树’";:二叉查找树
- Unity3D介绍
- [原创]K8飞刀Final