Cleanup: ensure header guards come first
authorCampbell Barton <ideasman42@gmail.com>
Wed, 9 Jan 2019 21:46:38 +0000 (08:46 +1100)
committerCampbell Barton <ideasman42@gmail.com>
Wed, 9 Jan 2019 21:46:38 +0000 (08:46 +1100)
Causes clang-format not to detect header guards,
indenting all preprocessor lines in the header.

intern/clog/CLG_log.h
intern/ghost/intern/GHOST_EventNDOF.h
intern/ghost/intern/GHOST_NDOFManager.h
source/blender/blenkernel/BKE_multires.h
source/blender/blenkernel/BKE_particle.h
source/blender/blenkernel/BKE_subdiv.h
source/blender/blenlib/BLI_endian_switch_inline.h
source/blender/editors/include/UI_resources.h
source/blender/makesrna/RNA_types.h

index 61fc93be9e7b27b96af7f5eb050376a887d7e80c..390122289b1d4c9fc2f906590972fd30382aed5c 100644 (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__ */
index b81f74becee7da1565eca564b84c10f2ac188f7a..a7a7639c98ececd945ab880cf41f177549f0f739 100644 (file)
  *  \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:
index 78f24e07a6ea8d75e3f3ad891cb5f91020821f69..b23673940e63d9fd630e2ad620828425e41e830a 100644 (file)
  * ***** 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
 
index 190ee9e7270f182893ecada5228da89f49a74904..bc01cc6b45c0cabbe8cf44ebc25445c0804f37c3 100644 (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__ */
index 5a1241f1de263db5bdea5e5fc92f48db362a79c1..ee8612c3d7b0befde4075ecde415c1017fa7ac79 100644 (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__ */
index 70572d3081958ff062e5679b81e41d404bfe173b..352581c99d6af6b13425fe2aeca08ddef6db65dc 100644 (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__ */
index 280503e9b93ab2729bb1b27e0ed598a8b5feef23..2be76e67b379e5f6c99b873ae917e12610d9d514 100644 (file)
  * ***** 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
  */
index 92871484e667de941cea21717979258c839a88d7..d686594f3340d4a0203a4599bc2bdad457ff2a85 100644 (file)
  *  \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,
index 72e1c05de3ce801f1067dd5398fb10145382502b..2c1bd2069b012bdcd76dd4226faa4443346329c7 100644 (file)
  *  \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