From 84289a2ba996b41815f148f27aecc52a7864066d Mon Sep 17 00:00:00 2001 From: peterbell10 Date: Sun, 10 May 2020 17:16:49 +0100 Subject: Cleanup some workarounds and warnings (#4735) * Cleanup thread_local usage in FastRandom * Use constexpr to avoid clang warning * Fix more Wglobal-constructor warnings * Make MSVC happy? --- src/Simulator/FireSimulator.cpp | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) (limited to 'src/Simulator/FireSimulator.cpp') diff --git a/src/Simulator/FireSimulator.cpp b/src/Simulator/FireSimulator.cpp index 2a9d6c289..f1b31ab8b 100644 --- a/src/Simulator/FireSimulator.cpp +++ b/src/Simulator/FireSimulator.cpp @@ -36,12 +36,7 @@ -#ifdef __clang__ - #pragma clang diagnostic push - #pragma clang diagnostic ignored "-Wglobal-constructors" -#endif - -static const Vector3i gCrossCoords[] = +static constexpr Vector3i gCrossCoords[] = { { 1, 0, 0}, {-1, 0, 0}, @@ -53,7 +48,7 @@ static const Vector3i gCrossCoords[] = -static const Vector3i gNeighborCoords[] = +static constexpr Vector3i gNeighborCoords[] = { { 1, 0, 0}, {-1, 0, 0}, @@ -61,11 +56,7 @@ static const Vector3i gNeighborCoords[] = { 0, -1, 0}, { 0, 0, 1}, { 0, 0, -1}, -} ; - -#ifdef __clang__ - #pragma clang diagnostic pop -#endif +}; -- cgit v1.2.3