Changes between Version 35 and Version 36 of Coding_Conventions
- Timestamp:
- Apr 22, 2018, 12:49:47 PM (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Coding_Conventions
v35 v36 212 212 1. The first non-comment line of **any** source file **must** be `#include "precompiled.h"` 213 213 1. For `.cpp` files that contain function implementations, headers that declare those functions should be included here. For instance, `#include "Simulation2.h"` for `Simulation2.cpp`, or `#include "ICmpPosition.h"` for `CCmpPosition.cpp`. 214 1. Include the files that come from the same folder. Do not write the complete path relative to `source/`, but rather the file name only. Use case-insensitive alphabetical order. 215 1. Include the files that come from the same project, but a different folder (even subdirectories of the current file's directory). Write the complete path relative to `source/`, for instance `#include "simulation2/Simulation2.h"`. Use case-insensitive alphabetical order. 216 1. Include the files that come from other projects. Write the complete path relative to `source/`, for instance `#include "lib/file/file.h"`. Use case-insensitive alphabetical order. 214 1. Include the rest of the files that come from 0 A.D. Write the complete path relative to `source/`, for instance `#include "simulation2/Simulation2.h"`. Use case-insensitive alphabetical order. 217 215 1. Include system libraries, in case-insensitive alphabetical order. 218 216 … … 223 221 224 222 #include "Simulation2.h" 225 226 #include "Example.h"227 #include "MessageTypes.h"228 229 #include "simulation2/components/ICmpAIManager.h"230 #include "simulation2/components/ICmpCommandQueue.h"231 #include "simulation2/components/ICmpTemplateManager.h"232 #include "simulation2/system/ComponentManager.h"233 #include "simulation2/system/ParamNode.h"234 223 235 224 #include "graphics/Terrain.h" … … 243 232 #include "scriptinterface/ScriptInterface.h" 244 233 #include "scriptinterface/ScriptRuntime.h" 234 #include "simulation2/components/ICmpAIManager.h" 235 #include "simulation2/components/ICmpCommandQueue.h" 236 #include "simulation2/components/ICmpTemplateManager.h" 237 #include "simulation2/MessageTypes.h" 238 #include "simulation2/system/ComponentManager.h" 239 #include "simulation2/system/ParamNode.h" 245 240 246 241 #include <iomanip>