Cleanup: ensure header guards come first

Causes clang-format not to detect header guards,
indenting all preprocessor lines in the header.
This commit is contained in:
Campbell Barton 2019-01-10 08:46:38 +11:00
parent 69c8f0cc3b
commit 5681631109
9 changed files with 22 additions and 25 deletions

View File

@ -18,8 +18,8 @@
* ***** END GPL LICENSE BLOCK *****
*/
#ifndef __CLOG_H__
#define __CLOG_H__
#ifndef __CLG_LOG_H__
#define __CLG_LOG_H__
/** \file clog/CLG_log.h
* \ingroup clog
@ -211,4 +211,4 @@ void CLG_logref_init(CLG_LogRef *clg_ref);
}
#endif
#endif /* __CLOG_H__ */
#endif /* __CLG_LOG_H__ */

View File

@ -24,16 +24,15 @@
* \ingroup GHOST
*/
#ifndef __GHOST_EVENTNDOF_H__
#define __GHOST_EVENTNDOF_H__
#ifndef WITH_INPUT_NDOF
# error NDOF code included in non-NDOF-enabled build
#endif
#ifndef __GHOST_EVENTNDOF_H__
#define __GHOST_EVENTNDOF_H__
#include "GHOST_Event.h"
class GHOST_EventNDOFMotion : public GHOST_Event
{
protected:

View File

@ -21,16 +21,15 @@
* ***** END GPL LICENSE BLOCK *****
*/
#ifndef __GHOST_NDOFMANAGER_H__
#define __GHOST_NDOFMANAGER_H__
#ifndef WITH_INPUT_NDOF
# error NDOF code included in non-NDOF-enabled build
#endif
#ifndef __GHOST_NDOFMANAGER_H__
#define __GHOST_NDOFMANAGER_H__
#include "GHOST_System.h"
// #define DEBUG_NDOF_MOTION
// #define DEBUG_NDOF_BUTTONS

View File

@ -163,6 +163,6 @@ BLI_INLINE void BKE_multires_construct_tangent_matrix(
const float dPdv[3],
const int corner);
#endif /* __BKE_MULTIRES_H__ */
#include "intern/multires_inline.h"
#endif /* __BKE_MULTIRES_H__ */

View File

@ -483,11 +483,11 @@ void BKE_particle_settings_eval_reset(
void BKE_particle_system_eval_init(struct Depsgraph *depsgraph,
struct Object *object);
#endif
/* Draw Cache */
enum {
BKE_PARTICLE_BATCH_DIRTY_ALL = 0,
};
void BKE_particle_batch_cache_dirty_tag(struct ParticleSystem *psys, int mode);
void BKE_particle_batch_cache_free(struct ParticleSystem *psys);
#endif /* __BKE_PARTICLE_H__ */

View File

@ -232,6 +232,6 @@ BLI_INLINE int BKE_subdiv_rotate_quad_to_corner(
const float u, const float v,
float *r_u, float *r_v);
#endif /* __BKE_SUBDIV_H__ */
#include "intern/subdiv_inline.h"
#endif /* __BKE_SUBDIV_H__ */

View File

@ -20,14 +20,14 @@
* ***** END GPL LICENSE BLOCK *****
*/
#ifndef __BLI_ENDIAN_SWITCH_INLINE_H__
#define __BLI_ENDIAN_SWITCH_INLINE_H__
/* only include from header */
#ifndef __BLI_ENDIAN_SWITCH_H__
# error "this file isnt to be directly included"
#endif
#ifndef __BLI_ENDIAN_SWITCH_INLINE_H__
#define __BLI_ENDIAN_SWITCH_INLINE_H__
/** \file blender/blenlib/BLI_endian_switch_inline.h
* \ingroup bli
*/

View File

@ -29,11 +29,11 @@
* \ingroup editorui
*/
#include "BLI_sys_types.h"
#ifndef __UI_RESOURCES_H__
#define __UI_RESOURCES_H__
#include "BLI_sys_types.h"
/* Define icon enum. */
#define DEF_ICON(name) ICON_##name,
#define DEF_ICON_VECTOR(name) ICON_##name,

View File

@ -24,12 +24,11 @@
* \ingroup RNA
*/
#include "../blenlib/BLI_sys_types.h"
#ifndef __RNA_TYPES_H__
#define __RNA_TYPES_H__
#include "../blenlib/BLI_sys_types.h"
#ifdef __cplusplus
extern "C" {
#endif