diff options
author | Jacques Lucke <jacques@blender.org> | 2022-01-10 19:02:05 +0300 |
---|---|---|
committer | Jacques Lucke <jacques@blender.org> | 2022-01-10 19:10:07 +0300 |
commit | b0a83a6ed496372a1508f43b3990687a29a4975f (patch) | |
tree | a7fe95200344d354f2a92697bd931cef1cdc8ef8 /source/blender/blenlib/tests/BLI_any_test.cc | |
parent | 292c2cefe30b3b4798324e0f04e3a4a529829c94 (diff) |
Fix compile error with msvc
Diffstat (limited to 'source/blender/blenlib/tests/BLI_any_test.cc')
-rw-r--r-- | source/blender/blenlib/tests/BLI_any_test.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/source/blender/blenlib/tests/BLI_any_test.cc b/source/blender/blenlib/tests/BLI_any_test.cc index 226088cf3c7..436a1d5fa4a 100644 --- a/source/blender/blenlib/tests/BLI_any_test.cc +++ b/source/blender/blenlib/tests/BLI_any_test.cc @@ -9,7 +9,7 @@ namespace blender::tests { TEST(any, DefaultConstructor) { - Any a; + Any<> a; EXPECT_FALSE(a.has_value()); } @@ -24,11 +24,11 @@ TEST(any, AssignInt) a = 10; EXPECT_EQ(value, 10); - Any b = a; + Any<> b = a; EXPECT_TRUE(b.has_value()); EXPECT_EQ(b.get<int>(), 10); - Any c = std::move(a); + Any<> c = std::move(a); EXPECT_TRUE(c); EXPECT_EQ(c.get<int>(), 10); @@ -48,11 +48,11 @@ TEST(any, AssignMap) map.add(4, 2); EXPECT_EQ((a.get<Map<int, int>>().lookup(4)), 2); - Any b = a; + Any<> b = a; EXPECT_TRUE(b); EXPECT_EQ((b.get<Map<int, int>>().lookup(4)), 2); - Any c = std::move(a); + Any<> c = std::move(a); c = c; EXPECT_TRUE(b); EXPECT_EQ((c.get<Map<int, int>>().lookup(4)), 2); @@ -64,9 +64,9 @@ TEST(any, AssignAny) { Any<> a = 5; Any<> b = std::string("hello"); - Any c; + Any<> c; - Any z; + Any<> z; EXPECT_FALSE(z.has_value()); z = a; |