diff options
author | ShadowNinja <shadowninja@minetest.net> | 2021-12-01 18:30:40 -0500 |
---|---|---|
committer | rubenwardy <rw@rubenwardy.com> | 2022-04-08 14:55:21 +0100 |
commit | 5683bb76cc3a60d952c9f58c41adaa5f195dd3f4 (patch) | |
tree | 86154779a5a23b1385a8e6872a7c3d79da51847d /src/unittest | |
parent | 3a87fab6c899afa50b2b7615b882d0a81b922832 (diff) | |
download | minetest-5683bb76cc3a60d952c9f58c41adaa5f195dd3f4.tar.gz minetest-5683bb76cc3a60d952c9f58c41adaa5f195dd3f4.tar.bz2 minetest-5683bb76cc3a60d952c9f58c41adaa5f195dd3f4.zip |
Fix compiler warnings
Diffstat (limited to 'src/unittest')
-rw-r--r-- | src/unittest/test_irrptr.cpp | 4 | ||||
-rw-r--r-- | src/unittest/test_voxelarea.cpp | 4 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/unittest/test_irrptr.cpp b/src/unittest/test_irrptr.cpp index 3484f1514..2fb7cfcd6 100644 --- a/src/unittest/test_irrptr.cpp +++ b/src/unittest/test_irrptr.cpp @@ -93,7 +93,9 @@ void TestIrrPtr::testRefCounting() #if defined(__clang__) #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wself-assign-overloaded" + #if __clang_major__ >= 7 + #pragma GCC diagnostic ignored "-Wself-assign-overloaded" + #endif #pragma GCC diagnostic ignored "-Wself-move" #endif diff --git a/src/unittest/test_voxelarea.cpp b/src/unittest/test_voxelarea.cpp index 9826d2ee7..1d72650d7 100644 --- a/src/unittest/test_voxelarea.cpp +++ b/src/unittest/test_voxelarea.cpp @@ -120,7 +120,7 @@ void TestVoxelArea::test_extent() VoxelArea v1(v3s16(-1337, -547, -789), v3s16(-147, 447, 669)); UASSERT(v1.getExtent() == v3s16(1191, 995, 1459)); - VoxelArea v2(v3s16(32493, -32507, 32753), v3s16(32508, -32492, 32768)); + VoxelArea v2(v3s16(32493, -32507, 32753), v3s16(32508, -32492, -32768)); UASSERT(v2.getExtent() == v3s16(16, 16, 16)); } @@ -129,7 +129,7 @@ void TestVoxelArea::test_volume() VoxelArea v1(v3s16(-1337, -547, -789), v3s16(-147, 447, 669)); UASSERTEQ(s32, v1.getVolume(), 1728980655); - VoxelArea v2(v3s16(32493, -32507, 32753), v3s16(32508, -32492, 32768)); + VoxelArea v2(v3s16(32493, -32507, 32753), v3s16(32508, -32492, -32768)); UASSERTEQ(s32, v2.getVolume(), 4096); } |