[Bf-blender-cvs] [04cfe4c] depsgraph_cleanup: Depsgraph: Cleanup of util headers

Sergey Sharybin noreply at git.blender.org
Thu May 26 13:55:08 CEST 2016


Commit: 04cfe4cca0843790744ab91357a248cab062c1f5
Author: Sergey Sharybin
Date:   Thu May 26 13:05:55 2016 +0200
Branches: depsgraph_cleanup
https://developer.blender.org/rB04cfe4cca0843790744ab91357a248cab062c1f5

Depsgraph: Cleanup of util headers

===================================================================

M	source/blender/depsgraph/util/deg_util_foreach.h
M	source/blender/depsgraph/util/deg_util_function.h
M	source/blender/depsgraph/util/deg_util_hash.h
M	source/blender/depsgraph/util/deg_util_map.h
M	source/blender/depsgraph/util/deg_util_set.h

===================================================================

diff --git a/source/blender/depsgraph/util/deg_util_foreach.h b/source/blender/depsgraph/util/deg_util_foreach.h
index 378ce77..cb7361f 100644
--- a/source/blender/depsgraph/util/deg_util_foreach.h
+++ b/source/blender/depsgraph/util/deg_util_foreach.h
@@ -28,8 +28,7 @@
  *  \ingroup depsgraph
  */
 
-#ifndef __DEPSGRAPH_UTIL_FOREACH_H__
-#define __DEPSGRAPH_UTIL_FOREACH_H__
+#pragma once
 
 #if (__cplusplus > 199711L) || (defined(_MSC_VER) && _MSC_VER >= 1800)
 #  define foreach(x, y) for(x : y)
@@ -47,5 +46,3 @@
 
 #  define foreach(x, y) for (x; false; (void)y)
 #endif
-
-#endif  /* __DEPSGRAPH_UTIL_FOREACH_H__ */
diff --git a/source/blender/depsgraph/util/deg_util_function.h b/source/blender/depsgraph/util/deg_util_function.h
index f10dbf5..be7d1e1 100644
--- a/source/blender/depsgraph/util/deg_util_function.h
+++ b/source/blender/depsgraph/util/deg_util_function.h
@@ -28,8 +28,7 @@
  *  \ingroup depsgraph
  */
 
-#ifndef __DEPSGRAPH_UTIL_FUNCTION_H__
-#define __DEPSGRAPH_UTIL_FUNCTION_H__
+#pragma once
 
 #if (__cplusplus > 199711L)
 
@@ -108,5 +107,3 @@ void *function_bind(T func,
 #define _4 Wrap()
 
 #endif
-
-#endif  /* __DEPSGRAPH_UTIL_FUNCTION_H__ */
diff --git a/source/blender/depsgraph/util/deg_util_hash.h b/source/blender/depsgraph/util/deg_util_hash.h
index 7a3acc1..c2b1d43 100644
--- a/source/blender/depsgraph/util/deg_util_hash.h
+++ b/source/blender/depsgraph/util/deg_util_hash.h
@@ -28,8 +28,7 @@
  *  \ingroup depsgraph
  */
 
-#ifndef __DEPSGRAPH_UTIL_HASH_H__
-#define __DEPSGRAPH_UTIL_HASH_H__
+#pragma once
 
 #if defined(DEG_NO_UNORDERED_MAP)
 #  define DEG_HASH_NAMESPACE_BEGIN
@@ -68,5 +67,3 @@ inline size_t hash_combine(size_t hash_a, size_t hash_b)
 {
 	return hash_a ^ (hash_b + 0x9e3779b9 + (hash_a << 6) + (hash_a >> 2));
 }
-
-#endif  /* __DEPSGRAPH_UTIL_HASH_H__ */
diff --git a/source/blender/depsgraph/util/deg_util_map.h b/source/blender/depsgraph/util/deg_util_map.h
index f65f6ed..fc99835 100644
--- a/source/blender/depsgraph/util/deg_util_map.h
+++ b/source/blender/depsgraph/util/deg_util_map.h
@@ -28,13 +28,10 @@
  *  \ingroup depsgraph
  */
 
-#ifndef __DEPSGRAPH_UTIL_MAP_H__
-#define __DEPSGRAPH_UTIL_MAP_H__
+#pragma once
 
 #include <map>
 
-#include "deg_util_hash.h"
-
 using std::map;
 using std::pair;
 
@@ -63,5 +60,3 @@ using std::tr1::unordered_map;
 #  error One of: DEG_NO_UNORDERED_MAP, DEG_TR1_UNORDERED_MAP,\
  DEG_STD_UNORDERED_MAP, DEG_STD_UNORDERED_MAP_IN_TR1_NAMESPACE must be defined!  // NOLINT
 #endif
-
-#endif  /* __DEPSGRAPH_UTIL_MAP_H__ */
diff --git a/source/blender/depsgraph/util/deg_util_set.h b/source/blender/depsgraph/util/deg_util_set.h
index 5766fce..3b30574 100644
--- a/source/blender/depsgraph/util/deg_util_set.h
+++ b/source/blender/depsgraph/util/deg_util_set.h
@@ -28,13 +28,10 @@
  *  \ingroup depsgraph
  */
 
-#ifndef __DEPSGRAPH_UTIL_SET_H__
-#define __DEPSGRAPH_UTIL_SET_H__
+#pragma once
 
 #include <set>
 
-#include "deg_util_hash.h"
-
 using std::set;
 
 #if defined(DEG_NO_UNORDERED_MAP)
@@ -62,5 +59,3 @@ using std::tr1::unordered_set;
 #  error One of: DEG_NO_UNORDERED_MAP, DEG_TR1_UNORDERED_MAP,\
  DEG_STD_UNORDERED_MAP, DEG_STD_UNORDERED_MAP_IN_TR1_NAMESPACE must be defined!  // NOLINT
 #endif
-
-#endif  /* __DEPSGRAPH_UTIL_SET_H__ */




More information about the Bf-blender-cvs mailing list