refactor: MakeTempSatPath 并入已有的 SAT 相关 namespace
- 不再为单个函数新建 namespace 块:把 SAT 相关的 find_nth_occurrence_reverse / fixACISFormat 整块上移到 RegionToString 之前, MakeTempSatPath 并入同一块,文件内 namespace 块数由 7 回到 6 - 编码规范补充:优先复用已有 namespace,整个文件没有时才新建
This commit is contained in:
1 parent
27cd7111fb
commit
3ba658ffc5
2 files changed
+64
-67
No files matched your search
+1
-1
@@ -146,7 +146,7 @@ set_debug_post_build(<target> "<Name>" ".arx")
|
||||
|
||||
## 编码规范
|
||||
|
||||
- **文件内私有函数用匿名 `namespace`**:只在一个 `.cpp` 内使用的函数,直接实现在该文件的匿名 `namespace { }` 中,不要写成文件级 `static`,也不要放进头文件。
|
||||
- **文件内私有函数用匿名 `namespace`**:只在一个 `.cpp` 内使用的函数,直接实现在该文件**已有的**匿名 `namespace { }` 中;只有整个文件没有匿名 namespace 时才新建一块。不要为每个函数单独开一块,也不要写成文件级 `static` 或放进头文件。
|
||||
|
||||
```cpp
|
||||
namespace {
|
||||
|
||||
Reference in new issue
Block a user