Fix compile issues with recent compilers

* Update wrap files
* Ignore clang's warning in doctest:

<ciso646> is not a standard header since C++20, use <version> to detect implementation-specific macros" [-Werror,-W#warnings]

Make sure app/doctest.h is used everywhere instead of directly including the header, so the warning is disabled everywhere
This commit is contained in:
Martin Leitner-Ankerl
2025-10-05 13:33:47 +02:00
parent 73f3cbb237
commit 39f9a06655
17 changed files with 45 additions and 42 deletions

View File

@@ -1,13 +1,13 @@
[wrap-file]
directory = abseil-cpp-20240722.0
source_url = https://github.com/abseil/abseil-cpp/releases/download/20240722.0/abseil-cpp-20240722.0.tar.gz
source_filename = abseil-cpp-20240722.0.tar.gz
source_hash = f50e5ac311a81382da7fa75b97310e4b9006474f9560ac46f54a9967f07d4ae3
patch_filename = abseil-cpp_20240722.0-1_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/abseil-cpp_20240722.0-1/get_patch
patch_hash = 692bbbc39cacaba4dc4b0c8b2fbbe32736c9cde6377acfa0d52088797af14ded
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/abseil-cpp_20240722.0-1/abseil-cpp-20240722.0.tar.gz
wrapdb_version = 20240722.0-1
directory = abseil-cpp-20250814.1
source_url = https://github.com/abseil/abseil-cpp/releases/download/20250814.1/abseil-cpp-20250814.1.tar.gz
source_filename = abseil-cpp-20250814.1.tar.gz
source_hash = 1692f77d1739bacf3f94337188b78583cf09bab7e420d2dc6c5605a4f86785a1
patch_filename = abseil-cpp_20250814.1-1_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/abseil-cpp_20250814.1-1/get_patch
patch_hash = f44ad4d72ff2919a6a48cf0887f69aef34c338bfdd8931153596e3766d75f654
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/abseil-cpp_20250814.1-1/abseil-cpp-20250814.1.tar.gz
wrapdb_version = 20250814.1-1
[provide]
absl_base = absl_base_dep

View File

@@ -1,10 +1,10 @@
[wrap-file]
directory = doctest-2.4.11
source_url = https://github.com/doctest/doctest/archive/refs/tags/v2.4.11.tar.gz
source_filename = doctest-2.4.11.tar.gz
source_hash = 632ed2c05a7f53fa961381497bf8069093f0d6628c5f26286161fbd32a560186
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/doctest_2.4.11-1/doctest-2.4.11.tar.gz
wrapdb_version = 2.4.11-1
directory = doctest-2.4.12
source_url = https://github.com/doctest/doctest/archive/refs/tags/v2.4.12.tar.gz
source_filename = doctest-2.4.12.tar.gz
source_hash = 73381c7aa4dee704bd935609668cf41880ea7f19fa0504a200e13b74999c2d70
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/doctest_2.4.12-1/doctest-2.4.12.tar.gz
wrapdb_version = 2.4.12-1
[provide]
dependency_names = doctest

View File

@@ -1,13 +1,13 @@
[wrap-file]
directory = fmt-11.0.2
source_url = https://github.com/fmtlib/fmt/archive/11.0.2.tar.gz
source_filename = fmt-11.0.2.tar.gz
source_hash = 6cb1e6d37bdcb756dbbe59be438790db409cdb4868c66e888d5df9f13f7c027f
patch_filename = fmt_11.0.2-1_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/fmt_11.0.2-1/get_patch
patch_hash = 90c9e3b8e8f29713d40ca949f6f93ad115d78d7fb921064112bc6179e6427c5e
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/fmt_11.0.2-1/fmt-11.0.2.tar.gz
wrapdb_version = 11.0.2-1
directory = fmt-11.2.0
source_url = https://github.com/fmtlib/fmt/archive/11.2.0.tar.gz
source_filename = fmt-11.2.0.tar.gz
source_hash = bc23066d87ab3168f27cef3e97d545fa63314f5c79df5ea444d41d56f962c6af
patch_filename = fmt_11.2.0-2_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/fmt_11.2.0-2/get_patch
patch_hash = cc555cbfc9e334d5b670763894586ad6fbaf7f85eb5e67221cfe519b919c6542
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/fmt_11.2.0-2/fmt-11.2.0.tar.gz
wrapdb_version = 11.2.0-2
[provide]
fmt = fmt_dep
dependency_names = fmt

View File

@@ -1,5 +1,5 @@
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest.h>
#include <app/doctest.h>
namespace doctest {

View File

@@ -3,7 +3,14 @@
#include <ankerl/unordered_dense.h>
#include <app/counter.h>
#if defined(__clang__)
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-W#warnings"
#endif
#include <doctest.h>
#if defined(__clang__)
# pragma clang diagnostic pop
#endif
#if defined(FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION)
# undef DOCTEST_REQUIRE

View File

@@ -1,9 +1,9 @@
#include <ankerl/unordered_dense.h> // for map, hash
#include <app/doctest.h> // for TestCase, skip, ResultBuilder
#include <app/geomean.h> // for geomean
#include <third-party/nanobench.h> // for Rng, doNotOptimizeAway, Bench
#include <doctest.h> // for TestCase, skip, ResultBuilder
#include <fmt/core.h> // for print, format
#include <chrono> // for duration, operator-, high_resolu...

View File

@@ -2,7 +2,7 @@
#include <ankerl/unordered_dense.h> // for map, operator==
#include <app/counting_allocator.h>
#include <app/doctest.h>
#include <third-party/nanobench.h>
#if __has_include("boost/unordered/unordered_flat_map.hpp")
@@ -16,7 +16,6 @@
# define HAS_BOOST_UNORDERED_FLAT_MAP() 0 // NOLINT(cppcoreguidelines-macro-usage)
#endif
#include <doctest.h>
#include <fmt/ostream.h>
#include <deque>

View File

@@ -1,7 +1,7 @@
#include <ankerl/unordered_dense.h> // for map
#include <app/doctest.h> // for TestCase, skip, TEST_CASE, test_...
#include <third-party/nanobench.h> // for Rng, doNotOptimizeAway, Bench
#include <doctest.h> // for TestCase, skip, TEST_CASE, test_...
#include <fmt/core.h> // for format
#include <cstddef> // for size_t

View File

@@ -171,7 +171,7 @@ test_exe = executable(
# see what's in the [provide] sections for the dependency names
dependency('doctest'),
dependency('fmt', method: fmt_method),
dependency('fmt', method: fmt_method, fallback: ['fmt', 'fmt_dep']),
# disable these two if you don't want them
#dependency('boost'),

View File

@@ -1,4 +1,4 @@
#include <doctest.h> // for TestCase, skip, TEST_CASE, test_...
#include <app/doctest.h> // for TestCase, skip, TEST_CASE, test_...
TEST_CASE("deduction_guide") {
// TODO(martinus) not yet possible, only in c++20. See

View File

@@ -1,6 +1,5 @@
#include <ankerl/unordered_dense.h>
#include <doctest.h> // for ResultBuilder, TestCase, REQUIRE
#include <app/doctest.h> // for ResultBuilder, TestCase, REQUIRE
#include <cstddef> // for size_t
#include <cstdint> // for uint64_t

View File

@@ -1,4 +1,4 @@
#include <doctest.h>
#include <app/doctest.h>
TEST_CASE("hash_char_types") {
// TODO(martinus) make hash generic?

View File

@@ -1,6 +1,6 @@
#include <ankerl/unordered_dense.h>
#include <doctest.h> // for ResultBuilder, TestCase, REQUIRE
#include <app/doctest.h> // for ResultBuilder, TestCase, REQUIRE
#include <cstdint> // for uint64_t
#include <memory> // for shared_ptr, __unique_ptr_t, make...

View File

@@ -1,6 +1,6 @@
#include <ankerl/unordered_dense.h>
#include <doctest.h>
#include <app/doctest.h>
#include <string>
#include <string_view>

View File

@@ -1,6 +1,5 @@
#include <ankerl/unordered_dense.h>
#include <doctest.h>
#include <app/doctest.h>
namespace versioned_namespace = ankerl::unordered_dense::v4_5_0;

View File

@@ -1,6 +1,6 @@
#include <ankerl/unordered_dense.h>
#include <doctest.h>
#include <app/doctest.h>
#include <cstddef> // for size_t
#include <string> // for allocator, string, operator==

View File

@@ -7,8 +7,7 @@
#include <ankerl/unordered_dense.h>
#include <app/counter.h>
#include <doctest.h>
#include <app/doctest.h>
#include <initializer_list>