From f8696742bb2a727886ab3c492eb0a8c7afba53bb Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Fri, 12 Jun 2020 15:15:09 +0200 Subject: Fix/workaround compilation error on devtoolset-6 Smells like GCC bug [1], which is backed up by the fact that locally GCC-10 and CLang-10 works fine. Since the change is trivial (and, arguably, correct since there is no real difference between tests code and actual code) seems fine to fix. Fix suggested by Jacques Lucke, thanks! [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=56480 --- tests/gtests/blenlib/BLI_set_test.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/gtests/blenlib/BLI_set_test.cc b/tests/gtests/blenlib/BLI_set_test.cc index 8e77a446a97..2387242c94b 100644 --- a/tests/gtests/blenlib/BLI_set_test.cc +++ b/tests/gtests/blenlib/BLI_set_test.cc @@ -9,7 +9,7 @@ #include "BLI_vector.hh" #include "testing/testing.h" -using namespace blender; +namespace blender { TEST(set, DefaultConstructor) { @@ -290,7 +290,7 @@ bool operator==(const Type2 &a, const Type1 &b) return a.value == b.value; } -template<> struct blender::DefaultHash { +template<> struct DefaultHash { uint32_t operator()(const Type1 &value) const { return value.value; @@ -511,3 +511,5 @@ TEST(set, Benchmark) */ #endif /* Benchmark */ + +} // namespace blender -- cgit v1.2.3