From c2aa3e2351c3a7eec912ce8f06fe8e9f72f6605c Mon Sep 17 00:00:00 2001 From: Marcel Admiraal Date: Tue, 8 Oct 2019 10:17:11 +0200 Subject: [PATCH] Remove circular include between core/typedefs.h and core/error_macros.h --- core/cowdata.h | 1 + core/list.h | 1 + core/map.h | 1 + core/math/math_funcs.cpp | 2 ++ core/os/memory.h | 1 + core/self_list.h | 1 + core/sort_array.h | 1 + core/typedefs.h | 1 - 8 files changed, 8 insertions(+), 1 deletion(-) diff --git a/core/cowdata.h b/core/cowdata.h index 3e40ad0f4b5b..c92e20920cd6 100644 --- a/core/cowdata.h +++ b/core/cowdata.h @@ -33,6 +33,7 @@ #include +#include "core/error_macros.h" #include "core/os/memory.h" #include "core/safe_refcount.h" diff --git a/core/list.h b/core/list.h index d1b528562d3b..c46888e01c50 100644 --- a/core/list.h +++ b/core/list.h @@ -31,6 +31,7 @@ #ifndef GLOBALS_LIST_H #define GLOBALS_LIST_H +#include "core/error_macros.h" #include "core/os/memory.h" #include "core/sort_array.h" diff --git a/core/map.h b/core/map.h index c87ee42e1bed..77e73d70cbbf 100644 --- a/core/map.h +++ b/core/map.h @@ -31,6 +31,7 @@ #ifndef MAP_H #define MAP_H +#include "core/error_macros.h" #include "core/set.h" // based on the very nice implementation of rb-trees by: diff --git a/core/math/math_funcs.cpp b/core/math/math_funcs.cpp index f04e40cb6cce..50fcdb2c1342 100644 --- a/core/math/math_funcs.cpp +++ b/core/math/math_funcs.cpp @@ -30,6 +30,8 @@ #include "math_funcs.h" +#include "core/error_macros.h" + RandomPCG Math::default_rand(RandomPCG::DEFAULT_SEED, RandomPCG::DEFAULT_INC); #define PHI 0x9e3779b9 diff --git a/core/os/memory.h b/core/os/memory.h index 8778cb63addb..a68a35954642 100644 --- a/core/os/memory.h +++ b/core/os/memory.h @@ -31,6 +31,7 @@ #ifndef MEMORY_H #define MEMORY_H +#include "core/error_macros.h" #include "core/safe_refcount.h" #include diff --git a/core/self_list.h b/core/self_list.h index 314d440977c1..07abcd1d536d 100644 --- a/core/self_list.h +++ b/core/self_list.h @@ -31,6 +31,7 @@ #ifndef SELF_LIST_H #define SELF_LIST_H +#include "core/error_macros.h" #include "core/typedefs.h" template diff --git a/core/sort_array.h b/core/sort_array.h index 8660ee3333a6..d330e0c647ce 100644 --- a/core/sort_array.h +++ b/core/sort_array.h @@ -31,6 +31,7 @@ #ifndef SORT_ARRAY_H #define SORT_ARRAY_H +#include "core/error_macros.h" #include "core/typedefs.h" #define ERR_BAD_COMPARE(cond) \ diff --git a/core/typedefs.h b/core/typedefs.h index 660139b90a18..767a97ac385f 100644 --- a/core/typedefs.h +++ b/core/typedefs.h @@ -108,7 +108,6 @@ T *_nullptr() { #include "core/int_types.h" #include "core/error_list.h" -#include "core/error_macros.h" /** Generic ABS function, for math uses please use Math::abs */