From e15a5ede18481f28f17b12ebaf318ea2cce82ff6 Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Wed, 31 May 2023 14:41:36 +0200 Subject: [PATCH] tests/hash: fix bug in MSVC compiler. --- tests/hash/ripemd160.cpp | 3 +++ tests/hash/sha256.cpp | 6 ++++++ 2 files changed, 9 insertions(+) diff --git a/tests/hash/ripemd160.cpp b/tests/hash/ripemd160.cpp index 086605a..383a231 100644 --- a/tests/hash/ripemd160.cpp +++ b/tests/hash/ripemd160.cpp @@ -52,6 +52,9 @@ TEST_CASE("hash::ripemd160::init/update/final") { const char *name; std::vector inputs; libantelope::ripemd160_t expected; +#ifdef _MSC_VER + char _; // ripemd160_t can't be last, wierd compiler bug on MSVC +#endif }; std::vector tests = { diff --git a/tests/hash/sha256.cpp b/tests/hash/sha256.cpp index 88b2744..8477cea 100644 --- a/tests/hash/sha256.cpp +++ b/tests/hash/sha256.cpp @@ -54,6 +54,9 @@ TEST_CASE("hash::sha256::sha256d") { const char *name; std::string input; libantelope::sha256_t expected; +#ifdef _MSC_VER + char _; // sha256_t can't be last, wierd compiler bug on MSVC +#endif }; std::vector tests = { @@ -106,6 +109,9 @@ TEST_CASE("hash::sha256::init/update/final") { const char *name; std::vector inputs; libantelope::sha256_t expected; +#ifdef _MSC_VER + char _; // sha256_t can't be last, wierd compiler bug on MSVC +#endif }; std::vector tests = {